This repository has been archived on 2024-03-07. You can view files and clone it, but cannot push or open issues/pull-requests.
wongola/doc/grammar.bnf

17 lines
212 B
BNF

PROG ::= INSTR*
INSTR ::=
| DIR
| EXPR semicolon
DIR ::= hash ident EXPR
EXPR ::=
| ADDSUB
ADDSUB ::= MULDIVMOD ((add|sub) MULDIVMOD)*
MULDIVMOD ::= LITERAL ((mul|div|mod) LITERAL)*
LITERAL ::=
| ident
| int