Documentation ¶
Overview ¶
Code generated by "ωBNF gen" DO NOT EDIT. $ wbnf gen --grammar ebnf.wbnf --start grammar --pkg ebnfparser --output ebnf.go
Index ¶
- Variables
- func GenerateOutput(grammar *EbnfGrammar, value *sysl.Value, logger *logrus.Logger) (string, error)
- func Grammar() parser.Parsers
- type AtomNode
- type CommentNode
- type EbnfGrammar
- type GrammarNode
- type IdentNode
- type ProdNode
- type StmtNode
- type Stopper
- type StringNode
- type TermNode
- type TermQuantNode
- type WalkerOps
- func (w WalkerOps) Walk(tree GrammarNode)
- func (w WalkerOps) WalkAtomNode(node AtomNode) Stopper
- func (w WalkerOps) WalkGrammarNode(node GrammarNode) Stopper
- func (w WalkerOps) WalkProdNode(node ProdNode) Stopper
- func (w WalkerOps) WalkStmtNode(node StmtNode) Stopper
- func (w WalkerOps) WalkTermNode(node TermNode) Stopper
- func (w WalkerOps) WalkTermQuantNode(node TermQuantNode) Stopper
- type WrapReNode
Constants ¶
This section is empty.
Variables ¶
View Source
var ( NodeExiter = &nodeExiter{} Aborter = &aborter{} )
Functions ¶
func GenerateOutput ¶
Types ¶
type CommentNode ¶
func (*CommentNode) String ¶
func (c *CommentNode) String() string
type EbnfGrammar ¶
func ReadGrammar ¶
type GrammarNode ¶
func NewGrammarNode ¶
func NewGrammarNode(from ast.Node) GrammarNode
func ParseString ¶
func ParseString(input string) (GrammarNode, error)
func (GrammarNode) AllStmt ¶
func (c GrammarNode) AllStmt() []StmtNode
func (GrammarNode) GetAstNode ¶
func (c GrammarNode) GetAstNode() ast.Node
type StmtNode ¶
func (StmtNode) OneComment ¶
func (c StmtNode) OneComment() *CommentNode
type StringNode ¶
func (*StringNode) String ¶
func (c *StringNode) String() string
type TermQuantNode ¶ added in v0.7.0
func (TermQuantNode) Choice ¶ added in v0.7.0
func (c TermQuantNode) Choice() int
func (TermQuantNode) OneToken ¶ added in v0.7.0
func (c TermQuantNode) OneToken() string
type WalkerOps ¶
type WalkerOps struct { EnterAtomNode func(AtomNode) Stopper ExitAtomNode func(AtomNode) Stopper EnterCommentNode func(CommentNode) Stopper ExitCommentNode func(CommentNode) Stopper EnterGrammarNode func(GrammarNode) Stopper ExitGrammarNode func(GrammarNode) Stopper EnterIdentNode func(IdentNode) Stopper ExitIdentNode func(IdentNode) Stopper EnterProdNode func(ProdNode) Stopper ExitProdNode func(ProdNode) Stopper EnterStmtNode func(StmtNode) Stopper ExitStmtNode func(StmtNode) Stopper EnterStringNode func(StringNode) Stopper ExitStringNode func(StringNode) Stopper EnterTermNode func(TermNode) Stopper ExitTermNode func(TermNode) Stopper EnterTermQuantNode func(TermQuantNode) Stopper ExitTermQuantNode func(TermQuantNode) Stopper EnterWrapReNode func(WrapReNode) Stopper ExitWrapReNode func(WrapReNode) Stopper }
func (WalkerOps) Walk ¶
func (w WalkerOps) Walk(tree GrammarNode)
func (WalkerOps) WalkAtomNode ¶ added in v0.7.0
func (WalkerOps) WalkGrammarNode ¶ added in v0.7.0
func (w WalkerOps) WalkGrammarNode(node GrammarNode) Stopper
func (WalkerOps) WalkProdNode ¶ added in v0.7.0
func (WalkerOps) WalkStmtNode ¶ added in v0.7.0
func (WalkerOps) WalkTermNode ¶ added in v0.7.0
func (WalkerOps) WalkTermQuantNode ¶ added in v0.7.0
func (w WalkerOps) WalkTermQuantNode(node TermQuantNode) Stopper
type WrapReNode ¶ added in v0.7.0
func (*WrapReNode) String ¶ added in v0.7.0
func (c *WrapReNode) String() string
Click to show internal directories.
Click to hide internal directories.