AntlrVSIX icon indicating copy to clipboard operation
AntlrVSIX copied to clipboard

In LBNF, the "category" (non-terminal) symbol can be enclosed in brackets

Open kaby76 opened this issue 5 years ago • 0 comments

In LBNF, a non-terminal can be enclosed in square brackets, which indicates it is used in a "polymorphic list"--ie a tuple with car and cdr, or a tuple with only a value.

[]. [Def] ::= ;
(:). [Def] ::= Def ";" [Def] ;

This means to create an AST as a binary tree using internal nodes with left/right and leaf nodes with one child.

So, the LBNF symbol tables need to be updated to record these defs and refs.

kaby76 avatar Dec 30 '20 14:12 kaby76