Class IrInstruction.TypeTest
Tests whether a value conforms to a type.
public sealed record IrInstruction.TypeTest : IrInstruction, IEquatable<IrInstruction>, IEquatable<IrInstruction.TypeTest>
- Inheritance
-
IrInstruction.TypeTest
- Implements
- Inherited Members
Constructors
TypeTest(TextSpan, int, int, TypeSymbol)
Tests whether a value conforms to a type.
public TypeTest(TextSpan Span, int Destination, int Source, TypeSymbol TestedType)
Parameters
SpanTextSpanThe source span.
DestinationintThe destination slot.
SourceintThe source slot.
TestedTypeTypeSymbolThe tested type.
Properties
Destination
The destination slot.
public int Destination { get; init; }
Property Value
EqualityContract
protected override Type EqualityContract { get; }
Property Value
Source
The source slot.
public int Source { get; init; }
Property Value
TestedType
The tested type.
public TypeSymbol TestedType { get; init; }
Property Value
Methods
Deconstruct(out TextSpan, out int, out int, out TypeSymbol)
public void Deconstruct(out TextSpan Span, out int Destination, out int Source, out TypeSymbol TestedType)
Parameters
SpanTextSpanDestinationintSourceintTestedTypeTypeSymbol
Equals(IrInstruction?)
public override sealed bool Equals(IrInstruction? other)
Parameters
otherIrInstruction
Returns
Equals(TypeTest?)
public bool Equals(IrInstruction.TypeTest? other)
Parameters
otherIrInstruction.TypeTest
Returns
Equals(object?)
public override bool Equals(object? obj)
Parameters
objobject
Returns
GetHashCode()
public override int GetHashCode()
Returns
PrintMembers(StringBuilder)
protected override bool PrintMembers(StringBuilder builder)
Parameters
builderStringBuilder
Returns
ToString()
public override string ToString()
Returns
Operators
operator ==(TypeTest?, TypeTest?)
public static bool operator ==(IrInstruction.TypeTest? left, IrInstruction.TypeTest? right)
Parameters
leftIrInstruction.TypeTestrightIrInstruction.TypeTest
Returns
operator !=(TypeTest?, TypeTest?)
public static bool operator !=(IrInstruction.TypeTest? left, IrInstruction.TypeTest? right)
Parameters
leftIrInstruction.TypeTestrightIrInstruction.TypeTest