Table of Contents

Class IrValidator

Namespace
MuLang.IR
Assembly
MuLang.IR.dll

Validates portable MuLang IR against its structural and environment contracts.

public static class IrValidator
Inheritance
IrValidator
Inherited Members

Methods

Validate(IrProgram, EnvironmentSchema)

Validates a program against an environment.

public static DiagnosticCollection Validate(IrProgram program, EnvironmentSchema environment)

Parameters

program IrProgram

The IR program to validate.

environment EnvironmentSchema

The expected provider environment.

Returns

DiagnosticCollection

The validation diagnostics.

Validate(IrProgram, EnvironmentSchema, CompilationMode?, LanguageProfileFingerprint?)

Validates a program against an environment and expected compilation metadata.

public static DiagnosticCollection Validate(IrProgram program, EnvironmentSchema environment, CompilationMode? expectedCompilationMode, LanguageProfileFingerprint? expectedLanguageProfileFingerprint)

Parameters

program IrProgram

The IR program to validate.

environment EnvironmentSchema

The expected provider environment.

expectedCompilationMode CompilationMode?

The expected compilation mode, or null to skip this check.

expectedLanguageProfileFingerprint LanguageProfileFingerprint

The expected profile fingerprint, or null to skip this check.

Returns

DiagnosticCollection

The validation diagnostics.