feat: add declare_syntax_cat command parser

This commit is contained in:
Leonardo de Moura 2020-01-10 20:38:08 -08:00
parent 799914daf2
commit 80e00a87c6

View file

@ -94,7 +94,8 @@ def openRenamingItem := parser! ident >> unicodeSymbol "→" "->" >> ident
def openRenaming := parser! try (ident >> "renaming") >> sepBy1 openRenamingItem ", "
def openOnly := parser! try (ident >> "(") >> many1 ident >> ")"
def openSimple := parser! many1 ident
@[builtinCommandParser] def «open» := parser! "open " >> (openHiding <|> openRenaming <|> openOnly <|> openSimple)
@[builtinCommandParser] def «open» := parser! "open " >> (openHiding <|> openRenaming <|> openOnly <|> openSimple)
@[builtinCommandParser] def syntaxCat := parser! "declare_syntax_cat " >> ident
/- Lean3 command declaration commands -/
def maxPrec := parser! symbolOrIdent "max"