|
Enhanced C#
Loyc library documentation
|
Represents an LLLPG rule, which is a Predicate plus a Name and optional attributes (e.g. token, private, etc.). More...
Represents an LLLPG rule, which is a Predicate plus a Name and optional attributes (e.g. token, private, etc.).
Public fields | |
| LNode | Basis |
A node that contains the original code of the rule, or, if the rule was created programmatically, the method prototype (e.g. #fn(int, Rule, #(#var(int, arg))), which means int Rule(int arg)). This can be null, in which case the default prototype is void Rule();, or if the rule is a starting rule or token, public void Rule();. More... | |
| LNode | ReturnType |
| readonly EndOfRule | EndOfRule |
| Symbol | Name |
| Pred | Pred |
| bool | IsToken |
| bool | IsStartingRule |
| bool | IsExternal |
| bool | IsInline |
| bool | IsPrivate |
| bool | FullLLk |
| int | K |
| LNode | TryWrapperName |
| bool | HasRecognizerVersion => _recognizer != null || IsRecognizer |
| Rule | Recognizer => _recognizer |
Properties | |
| bool | IsRecognizer [get, set] |
Public Member Functions | |
| Rule (LNode basis, Symbol name, Pred pred, bool isStartingRule=true, bool isRecognizer=false) | |
| Rule | GetOrMakeRecognizerVersion () |
| Rule | MakeRecognizerVersion (Symbol newName) |
| Rule | MakeRecognizerVersion (LNode prototype) |
| void | TryWrapperNeeded () |
| override string | ToString () |
| LNode | GetMethodSignature () |
| Returns Basis if it's a method signature; otherwise constructs a default signature. More... | |
Static Public Member Functions | |
| static Alts | operator| (Rule a, Pred b) |
| static Alts | operator| (Pred a, Rule b) |
| static Alts | operator| (Rule a, Rule b) |
| static Alts | operator/ (Rule a, Pred b) |
| static Alts | operator/ (Pred a, Rule b) |
| static Alts | operator/ (Rule a, Rule b) |
| static Pred | operator+ (Rule a, char b) |
| static Pred | operator+ (char a, Rule b) |
| static Pred | operator+ (Rule a, LNode b) |
| static Pred | operator+ (LNode a, Rule b) |
| static implicit | operator Rule (RuleRef rref) |
| static implicit | operator RuleRef (Rule rule) |
|
inline |
Returns Basis if it's a method signature; otherwise constructs a default signature.
| LNode Loyc.LLParserGenerator.Rule.Basis |
A node that contains the original code of the rule, or, if the rule was created programmatically, the method prototype (e.g. #fn(int, Rule, #(#var(int, arg))), which means int Rule(int arg)). This can be null, in which case the default prototype is void Rule();, or if the rule is a starting rule or token, public void Rule();.
The Basis is also used to provide an error location.
Referenced by Loyc.LLParserGenerator.CodeGenHelperBase.CallRule().
1.8.7