Dynamic Access
The dynamic access postfix operation accesses a named field within a structure.
Process
At runtime:
- the operand is evaluated; and
- the provided identifier is resolved as a member of the operand; and
- the result is the resolved member.
Enumeration variant payloads are not accessed dynamically; they are extracted by match expressions.
Assertions
- The operand is of a structure type.
- The accessed name is a field declared by that structure type.
Syntax
dynamic_access_operation = dot, identifier ;