Represents a scalar or aggregate initializer.
More...
#include <bond/compiler/parsenodes.h>
Represents a scalar or aggregate initializer.
◆ Initializer() [1/2]
| Bond::Initializer::Initializer |
( |
Expression * | expression | ) |
|
|
inlineexplicit |
Constructs a scalar initializer.
- Parameters
-
◆ Initializer() [2/2]
| Bond::Initializer::Initializer |
( |
const Token * | openBrace, |
|
|
Initializer * | initializerList ) |
|
inlineexplicit |
Constructs an aggregate initializer.
- Parameters
-
| openBrace | Token that opens the initializer list. |
| initializerList | Nested initializer list. |
◆ ~Initializer()
| virtual Bond::Initializer::~Initializer |
( |
| ) |
|
|
inlinevirtual |
◆ Accept() [1/2]
Dispatches this node to the given visitor.
- Parameters
-
| visitor | Visitor that handles this node type. |
Implements Bond::ParseNode.
◆ Accept() [2/2]
Dispatches this node to the given visitor.
- Parameters
-
| visitor | Visitor that handles this node type. |
Implements Bond::ParseNode.
◆ GetContextToken()
| virtual const Token * Bond::Initializer::GetContextToken |
( |
| ) |
const |
|
overridevirtual |
Returns the token used as source context for diagnostics.
- Returns
- A token associated with this node, or null if no token applies.
Implements Bond::ParseNode.
◆ GetExpression() [1/2]
Returns the scalar initializer expression.
◆ GetExpression() [2/2]
| const Expression * Bond::Initializer::GetExpression |
( |
| ) |
const |
|
inline |
Returns the scalar initializer expression.
◆ GetInitializerList() [1/2]
| Initializer * Bond::Initializer::GetInitializerList |
( |
| ) |
|
|
inline |
Returns nested initializer list for aggregates.
◆ GetInitializerList() [2/2]
| const Initializer * Bond::Initializer::GetInitializerList |
( |
| ) |
const |
|
inline |
Returns nested initializer list for aggregates.
◆ GetTypeDescriptor()
Returns the evaluated type descriptor for this initializer.
◆ IsResolved()
| virtual bool Bond::Initializer::IsResolved |
( |
| ) |
const |
|
virtual |
Returns true if this initializer and sub-initializers are resolved.
◆ SetTypeDescriptor()
| void Bond::Initializer::SetTypeDescriptor |
( |
const TypeDescriptor & | descriptor | ) |
|
|
inline |
Sets the evaluated type descriptor for this initializer.
- Parameters
-
| descriptor | Type descriptor to assign. |
The documentation for this class was generated from the following file:
- include/bond/compiler/parsenodes.h