Table of Contents

Interface IModuleAnalyzer

Namespace
RDCore.SDK.Model.Diagnostics
Assembly
RDCore.SDK.dll

Looks at a module and says what is worth saying about it (RD-VBAL §2.6.4).

public interface IModuleAnalyzer

Remarks

Implement this in an extension to add a diagnostic: the platform calls every analyzer it knows of for each document it diagnoses. An analyzer is a pure function of the ModuleAnalysisContext: it does not evaluate code, and it does not resolve names - what resolving found out is among the facts it is given.

Properties

Phase

The phase in which the analyzer is asked: the earliest that has everything it reads (AnalysisPhase).

AnalysisPhase Phase { get; }

Property Value

AnalysisPhase

Remarks

An analyzer that reads the syntax tree, or the facts of the static pass, is asked as soon as they are there and is not kept waiting for slower facts. One that reads Runtime overrides this to say so.

Methods

Analyze(ModuleAnalysisContext)

What the analyzer has to say about the module.

IEnumerable<AnalyzerFinding> Analyze(ModuleAnalysisContext context)

Parameters

context ModuleAnalysisContext

The module, and what is known of it.

Returns

IEnumerable<AnalyzerFinding>

Every finding, in no particular order; none when there is nothing to say.