Added a core namespace with a -main method; upversioned.

Also, Interactive read-eval-print loop, debugging, and other minor enhancements.
This commit is contained in:
Simon Brooke 2024-06-08 14:49:55 +01:00
parent f2a48cbe04
commit 4d3c36959c
9 changed files with 444 additions and 90 deletions

8
resources/grammar.bnf Normal file
View file

@ -0,0 +1,8 @@
EXPRESSION := NUMBER | NUMBER <SPACE> OPERATOR <SPACE> EXPRESSION
<NUMBER> := #'[IVXLCDM]+'
<OPERATOR> := ADD | SUBTRACT | MULTIPLY | DIVIDE
ADD := <'+'>
SUBTRACT := <'-'>
MULTIPLY := <'x'> | <'*'>
DIVIDE := <'/'>
SPACE := #'(?U)\s+'