Table of Contents

Class IrInstruction.Unary

Namespace
MuLang.IR
Assembly
MuLang.IR.dll

Applies a unary operation.

public sealed record IrInstruction.Unary : IrInstruction, IEquatable<IrInstruction>, IEquatable<IrInstruction.Unary>
Inheritance
IrInstruction.Unary
Implements
Inherited Members

Constructors

Unary(TextSpan, int, IrUnaryOperator, int)

Applies a unary operation.

public Unary(TextSpan Span, int Destination, IrUnaryOperator Operator, int Operand)

Parameters

Span TextSpan

The source span.

Destination int

The destination slot.

Operator IrUnaryOperator

The unary operator.

Operand int

The operand slot.

Properties

Destination

The destination slot.

public int Destination { get; init; }

Property Value

int

EqualityContract

protected override Type EqualityContract { get; }

Property Value

Type

Operand

The operand slot.

public int Operand { get; init; }

Property Value

int

Operator

The unary operator.

public IrUnaryOperator Operator { get; init; }

Property Value

IrUnaryOperator

Methods

Deconstruct(out TextSpan, out int, out IrUnaryOperator, out int)

public void Deconstruct(out TextSpan Span, out int Destination, out IrUnaryOperator Operator, out int Operand)

Parameters

Span TextSpan
Destination int
Operator IrUnaryOperator
Operand int

Equals(IrInstruction?)

public override sealed bool Equals(IrInstruction? other)

Parameters

other IrInstruction

Returns

bool

Equals(Unary?)

public bool Equals(IrInstruction.Unary? other)

Parameters

other IrInstruction.Unary

Returns

bool

Equals(object?)

public override bool Equals(object? obj)

Parameters

obj object

Returns

bool

GetHashCode()

public override int GetHashCode()

Returns

int

PrintMembers(StringBuilder)

protected override bool PrintMembers(StringBuilder builder)

Parameters

builder StringBuilder

Returns

bool

ToString()

public override string ToString()

Returns

string

Operators

operator ==(Unary?, Unary?)

public static bool operator ==(IrInstruction.Unary? left, IrInstruction.Unary? right)

Parameters

left IrInstruction.Unary
right IrInstruction.Unary

Returns

bool

operator !=(Unary?, Unary?)

public static bool operator !=(IrInstruction.Unary? left, IrInstruction.Unary? right)

Parameters

left IrInstruction.Unary
right IrInstruction.Unary

Returns

bool