Class BoundVariable
A simple name that is a variable: a parameter, a local or Static variable, or a field (MS-VBAL §5.6.10), whose value is read.
public sealed record BoundVariable : BoundNode, IEquatable<BoundNode>, IEquatable<BoundVariable>
- Inheritance
-
BoundVariable
- Implements
- Inherited Members
Remarks
What reading a name is - a call, a constant, an enumeration member's value, or a variable's value - depends on the symbol alone, and is decided once, here. A variable of the procedure the name is written in has its Slot in the procedure's FrameLayout.
Constructors
BoundVariable(SimpleNameExpressionNode, Symbol, FrameSlot?, bool)
A simple name that is a variable: a parameter, a local or Static variable, or a field (MS-VBAL §5.6.10), whose value is read.
public BoundVariable(SimpleNameExpressionNode Name, Symbol Variable, FrameSlot? Slot, bool IsAutoInstantiated)
Parameters
NameSimpleNameExpressionNodeThe simple name expression.
VariableSymbolThe variable the name resolves to.
SlotFrameSlot?The slot of the variable, when it is a parameter or a variable of the procedure the name is written in, and is not
Static.IsAutoInstantiatedboolWhether the variable is declared
As New(MS-VBAL §5.2.3.1.4): a reference to it creates the object it does not hold yet.
Remarks
What reading a name is - a call, a constant, an enumeration member's value, or a variable's value - depends on the symbol alone, and is decided once, here. A variable of the procedure the name is written in has its Slot in the procedure's FrameLayout.
Properties
IsAutoInstantiated
Whether the variable is declared As New (MS-VBAL §5.2.3.1.4): a reference to it creates the
object it does not hold yet.
public bool IsAutoInstantiated { get; init; }
Property Value
Name
The simple name expression.
public SimpleNameExpressionNode Name { get; init; }
Property Value
Slot
The slot of the variable, when it is a parameter or a variable of the procedure the name is written in, and is not Static.
public FrameSlot? Slot { get; init; }
Property Value
Variable
The variable the name resolves to.
public Symbol Variable { get; init; }