Skip to content
Concord

Class CodeMatch

Namespace
Concord
Assembly
Concord.Emit.dll

One step of a CodeMatcher search: either a specific opcode with an optional operand, or an arbitrary predicate a candidate instruction must satisfy.

public sealed class CodeMatch
Inheritance
CodeMatch
Inherited Members

Constructors

CodeMatch(Predicate<CodeInstruction>, string?)

Matches any instruction that satisfies an arbitrary predicate.

public CodeMatch(Predicate<CodeInstruction> predicate, string? name = null)

Parameters

predicate Predicate<CodeInstruction>

The test a candidate instruction must satisfy.

name string

Reserved for a future named-capture lookup. Not read by any member in this version.

Exceptions

ConcordEmitException

Thrown with code CONC120 when predicate is null.

CodeMatch(OpCode, object?, string?)

Matches a specific opcode and, optionally, its operand.

public CodeMatch(OpCode opcode, object? operand = null, string? name = null)

Parameters

opcode OpCode

The opcode a candidate instruction must carry.

operand object

The operand to require, or null to match any operand.

name string

Reserved for a future named-capture lookup. Not read by any member in this version.