Bond 0.9
C++ Bond Runtime Library API Documentation
Loading...
Searching...
No Matches
Bond::NativeBlock Class Reference

Represents a native declaration block. More...

#include <bond/compiler/parsenodes.h>

Inheritance diagram for Bond::NativeBlock:
Bond::ListParseNode Bond::ParseNode

Public Member Functions

 NativeBlock (const Token *keyword, ListParseNode *declarationList)
 Constructs a native block.
virtual ~NativeBlock ()
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.
const Token * GetKeyword () const
 Returns the token introducing this native block.
ListParseNode * GetNativeDeclarationList ()
 Returns native declarations contained in this block.
const ListParseNode * GetNativeDeclarationList () const
 Returns native declarations contained in this block.
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::ListParseNode
 ListParseNode ()
Protected Member Functions inherited from Bond::ParseNode
 ParseNode ()

Detailed Description

Represents a native declaration block.

Constructor & Destructor Documentation

◆ NativeBlock()

Bond::NativeBlock::NativeBlock ( const Token * keyword,
ListParseNode * declarationList )
inline

Constructs a native block.

Parameters
keywordNative block keyword token.
declarationListList of declarations in the block.

◆ ~NativeBlock()

virtual Bond::NativeBlock::~NativeBlock ( )
inlinevirtual

Member Function Documentation

◆ Accept() [1/2]

virtual void Bond::NativeBlock::Accept ( ParseNodeVisitor & visitor) const
inlineoverridevirtual

Dispatches this node to the given visitor.

Parameters
visitorVisitor that handles this node type.

Implements Bond::ParseNode.

◆ Accept() [2/2]

virtual void Bond::NativeBlock::Accept ( ParseNodeVisitor & visitor)
inlineoverridevirtual

Dispatches this node to the given visitor.

Parameters
visitorVisitor that handles this node type.

Implements Bond::ParseNode.

◆ GetContextToken()

virtual const Token * Bond::NativeBlock::GetContextToken ( ) const
inlineoverridevirtual

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.

◆ GetKeyword()

const Token * Bond::NativeBlock::GetKeyword ( ) const
inline

Returns the token introducing this native block.

◆ GetNativeDeclarationList() [1/2]

ListParseNode * Bond::NativeBlock::GetNativeDeclarationList ( )
inline

Returns native declarations contained in this block.

◆ GetNativeDeclarationList() [2/2]

const ListParseNode * Bond::NativeBlock::GetNativeDeclarationList ( ) const
inline

Returns native declarations contained in this block.


The documentation for this class was generated from the following file:
  • include/bond/compiler/parsenodes.h