EBNFGrammar

Undocumented in source.
class EBNFGrammar {}

Constructors

this
this(SymbolInfo[string] symbolInfos, EBNFGrammar origGrammar_)
Undocumented in source.

Members

Functions

addProduction
void addProduction(Production* p)
Undocumented in source. Be warned that the author may not have intended to support it.
calcNonterminalCanBeEmpty
void calcNonterminalCanBeEmpty()
Undocumented in source. Be warned that the author may not have intended to support it.
calcNonterminalCanBeEmpty
void calcNonterminalCanBeEmpty(BitSet!NonterminalID nonterminalCanBeEmpty, BitSet!NonterminalID nonterminalCanBeNonEmpty, bool checkNoOptEmpty)
Undocumented in source. Be warned that the author may not have intended to support it.
calcNonterminalTypes
void calcNonterminalTypes()
Undocumented in source. Be warned that the author may not have intended to support it.
canBeEmpty
bool canBeEmpty(Symbol symbol)
Undocumented in source. Be warned that the author may not have intended to support it.
canBeNonEmpty
bool canBeNonEmpty(Symbol symbol)
Undocumented in source. Be warned that the author may not have intended to support it.
canForward
bool canForward(Production* p, size_t symbolNr)
Undocumented in source. Be warned that the author may not have intended to support it.
canForwardPrefix
bool canForwardPrefix(Production* p, size_t symbolNr)
Undocumented in source. Be warned that the author may not have intended to support it.
directUnwrapClosure
immutable(NonterminalWithConstraint)[] directUnwrapClosure(NonterminalID s, immutable(Symbol)[] negLookaheads, immutable(TagUsage)[] tags)
Undocumented in source. Be warned that the author may not have intended to support it.
directUnwrapClosure
immutable(NonterminalWithConstraint)[] directUnwrapClosure(SymbolInstance s)
Undocumented in source. Be warned that the author may not have intended to support it.
directUnwrapClosure
immutable(NonterminalWithConstraint)[] directUnwrapClosure(NonterminalWithConstraint n)
Undocumented in source. Be warned that the author may not have intended to support it.
directUnwrapClosureHasSelf
bool directUnwrapClosureHasSelf(NonterminalID s, immutable(Symbol)[] negLookaheads, immutable(TagUsage)[] tags)
Undocumented in source. Be warned that the author may not have intended to support it.
directUnwrapClosureHasSelf
bool directUnwrapClosureHasSelf(NonterminalWithConstraint n)
Undocumented in source. Be warned that the author may not have intended to support it.
directUnwrapClosureMap
immutable(Symbol)[][NonterminalID] directUnwrapClosureMap(NonterminalID s, immutable(Symbol)[] negLookaheads, immutable(TagUsage)[] tags)
Undocumented in source. Be warned that the author may not have intended to support it.
directUnwrapClosureMap
immutable(Symbol)[][NonterminalID] directUnwrapClosureMap(NonterminalWithConstraint n)
Undocumented in source. Be warned that the author may not have intended to support it.
fillProductionsForNonterminal
void fillProductionsForNonterminal()
Undocumented in source. Be warned that the author may not have intended to support it.
firstSet
BitSet!TokenID firstSet(SymbolInstance[] symbols, Constraint extraConstraint, bool isFirst)
Undocumented in source. Be warned that the author may not have intended to support it.
firstSetContains
bool firstSetContains(SymbolInstance[] symbols, TokenID t)
Undocumented in source. Be warned that the author may not have intended to support it.
firstSetImpl
BitSet!TokenID firstSetImpl(const(Symbol) x, immutable(Symbol)[] negLookaheads, immutable(TagUsage)[] tags)
Undocumented in source. Be warned that the author may not have intended to support it.
getProductions
const(Production*)[] getProductions(NonterminalID symbol)
Undocumented in source.
getRewriteRules
const(RewriteRule)[] getRewriteRules(Production* p)
Undocumented in source. Be warned that the author may not have intended to support it.
getSymbolName
string getSymbolName(Symbol s)
Undocumented in source. Be warned that the author may not have intended to support it.
hasExactToken
bool hasExactToken(Symbol symbol, TokenID currentToken)
Undocumented in source. Be warned that the author may not have intended to support it.
hasNonTrivialRewriteRule
bool hasNonTrivialRewriteRule(Production* p)
Undocumented in source. Be warned that the author may not have intended to support it.
isDirectUnwrapProduction
bool isDirectUnwrapProduction(Production production)
Undocumented in source. Be warned that the author may not have intended to support it.
isProductionAllowed
bool isProductionAllowed(NonterminalWithConstraint n, Production* p)
Undocumented in source. Be warned that the author may not have intended to support it.
isSimpleProduction
bool isSimpleProduction(Production production)
Undocumented in source. Be warned that the author may not have intended to support it.
isValid
bool isValid(Symbol s)
Undocumented in source. Be warned that the author may not have intended to support it.
nextNonterminalWithConstraint
NonterminalWithConstraint nextNonterminalWithConstraint(Constraint c, SymbolInstance s, bool first)
Undocumented in source. Be warned that the author may not have intended to support it.
nextSymbolWithConstraint
SymbolWithConstraint nextSymbolWithConstraint(Constraint c, SymbolInstance s, bool first)
Undocumented in source. Be warned that the author may not have intended to support it.
orConstraint
Constraint orConstraint(Constraint a, Constraint b)
Undocumented in source. Be warned that the author may not have intended to support it.
origGrammar
EBNFGrammar origGrammar()
Undocumented in source. Be warned that the author may not have intended to support it.
productionString
string productionString(Production* p)
Undocumented in source. Be warned that the author may not have intended to support it.
productionStringRhs
string productionStringRhs(Production* p)
Undocumented in source. Be warned that the author may not have intended to support it.
productions
auto productions()
Undocumented in source. Be warned that the author may not have intended to support it.
symbolInstanceToString
string symbolInstanceToString(SymbolInstance s, bool includeAll, bool escape)
Undocumented in source. Be warned that the author may not have intended to support it.
symbolInstanceToString
string symbolInstanceToString(SymbolInstance[] symbols, bool includeAll, bool escape)
Undocumented in source. Be warned that the author may not have intended to support it.
symbolInstanceToString
void symbolInstanceToString(Appender!string app, SymbolInstance s, bool includeAll, bool escape)
Undocumented in source. Be warned that the author may not have intended to support it.
toString
string toString()
Undocumented in source. Be warned that the author may not have intended to support it.

Structs

FirstSetsKey
struct FirstSetsKey
Undocumented in source.

Variables

allowTokenNonterminals
bool allowTokenNonterminals;
Undocumented in source.
directUnwrapClosureCache
immutable(NonterminalWithConstraint)[][NonterminalWithConstraint] directUnwrapClosureCache;
Undocumented in source.
directUnwrapClosureMapCache
immutable(Symbol)[][NonterminalID][NonterminalWithConstraint] directUnwrapClosureMapCache;
Undocumented in source.
firstSetsCache
BitSet!TokenID[FirstSetsKey] firstSetsCache;
Undocumented in source.
firstSetsNonterminalCache
BitSet!NonterminalID[FirstSetsKey] firstSetsNonterminalCache;
Undocumented in source.
hasExactTokenCache
bool[NonterminalID][TokenID] hasExactTokenCache;
Undocumented in source.
inContextOnlyTokens
immutable(TokenID)[] inContextOnlyTokens;
Undocumented in source.
isLexerGrammar
bool isLexerGrammar;
Undocumented in source.
matchingTokens
TokenID[2][] matchingTokens;
Undocumented in source.
nonterminals
IDMap!(NonterminalID, Nonterminal) nonterminals;
Undocumented in source.
origGrammar_
EBNFGrammar origGrammar_;
Undocumented in source.
productionsData
const(Production*)[] productionsData;
Undocumented in source.
startNonterminalID
size_t startNonterminalID;
Undocumented in source.
startNonterminals
StartNonterminal[] startNonterminals;
Undocumented in source.
startProductionID
size_t startProductionID;
Undocumented in source.
startTokenID
size_t startTokenID;
Undocumented in source.
symbolInfos
SymbolInfo[string] symbolInfos;
Undocumented in source.
symbolsInMultiplePaths
bool[Symbol] symbolsInMultiplePaths;
Undocumented in source.
tags
IDMap!(TagID, Tag) tags;
Undocumented in source.
tokens
IDMap!(TokenID, Token) tokens;
Undocumented in source.

Meta