Scope

Contains symbols and supports lookup of symbols by cursor position.

Disabled Default Constructor

A disabled default is present on this object. To use it, use one of the other constructors or a factory function.

Constructors

this
this(uint begin, uint end)

Destructor

A destructor is present on this object, but not explicitly documented in the source.

Postblit

Copying this object is disabled.

A postblit is present on this object, but not explicitly documented in the source.

Members

Functions

addSymbol
void addSymbol(DSymbol* symbol, bool owns)

Adds the given symbol to this scope.

getScopeByCursor
Scope* getScopeByCursor(size_t cursorPosition)
getSymbolsAtGlobalScope
inout(DSymbol)*[] getSymbolsAtGlobalScope(istring name)

Returns an array of symbols that are present at global scope

getSymbolsByName
inout(DSymbol)*[] getSymbolsByName(istring name)
getSymbolsByNameAndCursor
DSymbol*[] getSymbolsByNameAndCursor(istring name, size_t cursorPosition)
getSymbolsInCursorScope
DSymbol*[] getSymbolsInCursorScope(size_t cursorPosition)

Variables

children
UnrolledList!(Scope*, Mallocator, false) children;

Child scopes

endLocation
uint endLocation;

End location of this scope in bytes

parent
Scope* parent;

The scope that contains this one

startLocation
uint startLocation;

Start location of this scope in bytes

Meta