|
Bond 0.9
C++ Bond Runtime Library API Documentation
|
Represents a ternary conditional expression. More...
#include <bond/compiler/parsenodes.h>
Public Member Functions | |
| ConditionalExpression (const Token *op, Expression *condition, Expression *trueExpression, Expression *falseExpression) | |
| Constructs a conditional expression. | |
| virtual | ~ConditionalExpression () |
| 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 const Token * | GetContextToken () const override |
| Returns the token used as source context for diagnostics. | |
| Expression * | GetCondition () |
| Returns the condition expression. | |
| const Expression * | GetCondition () const |
| Returns the condition expression. | |
| Expression * | GetTrueExpression () |
| Returns the true branch expression. | |
| const Expression * | GetTrueExpression () const |
| Returns the true branch expression. | |
| Expression * | GetFalseExpression () |
| Returns the false branch expression. | |
| const Expression * | GetFalseExpression () const |
| Returns the false branch expression. | |
| Public Member Functions inherited from Bond::Expression | |
| virtual | ~Expression () |
| const TypeDescriptor & | GetTypeDescriptor () const |
| Returns the expression's type descriptor. | |
| void | SetTypeDescriptor (const TypeDescriptor &descriptor) |
| Sets the expression's type descriptor. | |
| const TypeAndValue & | GetTypeAndValue () const |
| Returns type and value metadata for the expression. | |
| TypeAndValue & | GetTypeAndValue () |
| Returns mutable type and value metadata for the expression. | |
| Public Member Functions inherited from Bond::ListParseNode | |
| virtual | ~ListParseNode () |
| 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 () |
Additional Inherited Members | |
| Protected Member Functions inherited from Bond::Expression | |
| Expression () | |
| Protected Member Functions inherited from Bond::ListParseNode | |
| ListParseNode () | |
| Protected Member Functions inherited from Bond::ParseNode | |
| ParseNode () | |
Represents a ternary conditional expression.
|
inline |
Constructs a conditional expression.
| op | Conditional operator token. |
| condition | Condition expression. |
| trueExpression | Expression evaluated when condition is true. |
| falseExpression | Expression evaluated when condition is false. |
|
inlinevirtual |
|
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.
|
inline |
Returns the condition expression.
|
inline |
Returns the condition expression.
|
inlineoverridevirtual |
Returns the token used as source context for diagnostics.
Implements Bond::ParseNode.
|
inline |
Returns the false branch expression.
|
inline |
Returns the false branch expression.
|
inline |
Returns the true branch expression.
|
inline |
Returns the true branch expression.