Joos1W Compiler Framework
|
Immutable struct that represents a unique identifier for a scope. This captures the position of the lexical scope in the AST to be used after AST construction, when lexical information has been lost. More...
#include <AstNode.h>
Public Member Functions | |
ScopeID const * | next (BumpAllocator &alloc, ScopeID const *parent) const |
Move on to the next declaration in the given scope. More... | |
bool | canView (ScopeID const *other) const |
Returns true if we can view the "other" scope from this scope. More... | |
const ScopeID * | parent () const |
std::string | toString () const |
std::ostream & | print (std::ostream &os) const |
void | dump () const |
Static Public Member Functions | |
static const ScopeID * | New (BumpAllocator &alloc) |
Friends | |
std::ostream & | operator<< (std::ostream &os, const ScopeID &id) |
Immutable struct that represents a unique identifier for a scope. This captures the position of the lexical scope in the AST to be used after AST construction, when lexical information has been lost.
bool ast::ScopeID::canView | ( | ScopeID const * | other | ) | const |
Returns true if we can view the "other" scope from this scope.
other | The other scope we want to view |
Definition at line 24 of file ScopeID.cc.
References canView().
Referenced by canView().
Move on to the next declaration in the given scope.
alloc | The allocator to allocate the new scope |
parent | The parent scope |
Definition at line 361 of file AstNode.h.
Referenced by ast::Semantic::EnterLexicalScope(), and ast::Semantic::ExitLexicalScope().