|
Bond 0.9
C++ Bond Runtime Library API Documentation
|
Represents one labeled section inside a switch statement. More...
#include <bond/compiler/parsenodes.h>
Public Member Functions | |
| SwitchSection (SwitchLabel *labelList, ListParseNode *statementList) | |
| Constructs a switch section. | |
| virtual | ~SwitchSection () |
| Destroys a SwitchSection object. | |
| virtual void | Accept (ParseNodeVisitor &visitor) override |
| Dispatches this node to the given visitor. | |
| virtual void | Accept (ParseNodeVisitor &visitor) const override |
| Dispatches this node to the given visitor. | |
| virtual SymbolType | GetSymbolType () const override |
| Returns the concrete symbol type. | |
| SwitchLabel * | GetLabelList () |
| Returns the label list for this section. | |
| const SwitchLabel * | GetLabelList () const |
| Returns the label list for this section. | |
| ListParseNode * | GetStatementList () |
| Returns the statement list for this section. | |
| const ListParseNode * | GetStatementList () const |
| Returns the statement list for this section. | |
| size_t | GetJumpTargetId () const |
| Returns the jump target ID assigned to this section. | |
| void | SetJumpTargetId (size_t id) |
| Sets the jump target ID assigned to this section. | |
| virtual UsingDirective * | GetUsingNamespaceList () override |
| Returns the list of namespaces opened in this scope via using-directives. | |
| virtual const UsingDirective * | GetUsingNamespaceList () const override |
| Returns the list of namespaces opened in this scope via using-directives. | |
| virtual void | AddUsingNamespace (UsingDirective *usingDirective) override |
| Opens a namespace into this scope, making its members visible to unqualified lookup. | |
| Public Member Functions inherited from Bond::Symbol | |
| virtual | ~Symbol () |
| Destroys a Symbol object. | |
| virtual const Token * | GetContextToken () const override |
| Returns the token used as source context for diagnostics. | |
| virtual const Token * | GetName () const |
| Returns the symbol name token. | |
| virtual TypeAndValue * | GetTypeAndValue () |
| Returns the symbol's type-and-value metadata. | |
| virtual const TypeAndValue * | GetTypeAndValue () const |
| Returns the symbol's type-and-value metadata. | |
| virtual bool | IsResolved () const |
| Returns true when symbol resolution has completed for this symbol. | |
| bool | IsTypeDefinition () const |
| Returns true if this symbol defines a type, i.e. it is a struct or an enum. | |
| Symbol * | GetParentSymbol () |
| Returns the enclosing symbol. | |
| const Symbol * | GetParentSymbol () const |
| Returns the enclosing symbol. | |
| void | SetParentSymbol (Symbol *parent) |
| Sets the enclosing symbol. | |
| Symbol * | FindSymbol (const StringView &name) |
| Finds a directly contained symbol by name. | |
| const Symbol * | FindSymbol (const StringView &name) const |
| Finds a directly contained symbol by name. | |
| Symbol * | FindSymbol (const Token *name) |
| Finds a directly contained symbol by token text. | |
| const Symbol * | FindSymbol (const Token *name) const |
| Finds a directly contained symbol by token text. | |
| Symbol * | FindSymbol (const QualifiedIdentifier *identifier) |
| Finds a symbol referenced by a qualified identifier. | |
| const Symbol * | FindSymbol (const QualifiedIdentifier *identifier) const |
| Finds a symbol referenced by a qualified identifier. | |
| Symbol * | FindSymbol (const QualifiedIdentifier *identifier, bool &isAmbiguous) |
| Finds a symbol referenced by a qualified identifier, flagging ambiguous matches. | |
| const Symbol * | FindSymbol (const QualifiedIdentifier *identifier, bool &isAmbiguous) const |
| Finds a symbol referenced by a qualified identifier, flagging ambiguous matches. | |
| void | InsertSymbol (Symbol *symbol) |
| Inserts a symbol at the front of this symbol's child list and sets this symbol as its parent. | |
| bool | IsAnonymous () const |
| Returns true if this symbol has no explicit name. | |
| bool | Matches (const StringView &name) const |
| Returns true if this symbol's name matches the given text. | |
| virtual Symbol * | Resolve () |
| Returns the symbol that lookups through this symbol should ultimately resolve to. | |
| virtual const Symbol * | Resolve () const |
| Returns the symbol that lookups through this symbol should ultimately resolve to. | |
| Public Member Functions inherited from Bond::ListParseNode | |
| virtual | ~ListParseNode () |
| Destroys a ListParseNode object. | |
| ListParseNode * | GetNextNode () |
| Returns the next node in the list. | |
| const ListParseNode * | GetNextNode () const |
| Returns the next node in the list. | |
| void | SetNextNode (ListParseNode *next) |
| Sets the next node in the list. | |
| Public Member Functions inherited from Bond::ParseNode | |
| virtual | ~ParseNode () |
| Destroys a ParseNode object. | |
Additional Inherited Members | |
| Public Types inherited from Bond::Symbol | |
| enum | SymbolType { TYPE_NAMESPACE , TYPE_STRUCT , TYPE_ENUM , TYPE_LOCALSCOPE , TYPE_VALUE , TYPE_FUNCTION } |
| Identifies the concrete symbol category. More... | |
| Protected Member Functions inherited from Bond::Symbol | |
| Symbol () | |
| Protected Member Functions inherited from Bond::ListParseNode | |
| ListParseNode () | |
| Protected Member Functions inherited from Bond::ParseNode | |
| ParseNode () | |
Represents one labeled section inside a switch statement.
|
inline |
Constructs a switch section.
| labelList | List of case/default labels. |
| statementList | List of statements for this section. |
|
inlinevirtual |
Destroys a SwitchSection object.
|
inlineoverridevirtual |
Dispatches this node to the given visitor.
| visitor | Visitor that handles this node type. |
Implements Bond::ParseNode.
|
inlineoverridevirtual |
Dispatches this node to the given visitor.
| visitor | Visitor that handles this node type. |
Implements Bond::ParseNode.
|
overridevirtual |
Opens a namespace into this scope, making its members visible to unqualified lookup.
| usingDirective | Using-directive node to link into this scope's opened-namespace list. |
Reimplemented from Bond::Symbol.
|
inline |
Returns the jump target ID assigned to this section.
|
inline |
Returns the label list for this section.
|
inline |
Returns the label list for this section.
|
inline |
Returns the statement list for this section.
|
inline |
Returns the statement list for this section.
|
inlineoverridevirtual |
Returns the concrete symbol type.
Implements Bond::Symbol.
|
inlineoverridevirtual |
Returns the list of namespaces opened in this scope via using-directives.
Reimplemented from Bond::Symbol.
|
inlineoverridevirtual |
Returns the list of namespaces opened in this scope via using-directives.
Reimplemented from Bond::Symbol.
|
inline |
Sets the jump target ID assigned to this section.
| id | Jump target identifier. |