Commit graph

9 commits

Author SHA1 Message Date
Alex Bethel 2c35691ec4 Add Brainfuck functio interpretation
BF functios can now be declared and called from AbleScript code.
Function parameters supplied from AbleScript are serialized manually
into byte sequences using the `BfWriter` trait, and are available from
BF code using the input operator, `,`.

At the moment, BF functios simply write output to stdout, and are
therefore incapable of communicating results to the rest of the
program; this might change in the future if we can get something close
to pass-by-reference working.
2021-06-02 15:29:31 -05:00
Alex Bethel 7bfefd3ba1 Add some unit tests to interpret.rs
Currently `overflow_should_not_panic` and `variable_persistence` both
fail due to bugs in the interpreter.
2021-05-30 13:32:29 -05:00
Alexander Bethel 7537b4ac98 Implement break and hopback statements 2021-05-25 21:22:38 -05:00
Alexander Bethel e31b8fb00d Implement basic interpreter
Added code for interpreting parsed AbleScript expressions and
statements, and hooked it up to the REPL.
2021-05-20 18:18:01 -05:00
Erin 00a464321a Added parsing of conditionals 2021-04-27 13:48:56 +02:00
Erin 2a0b2952d4 Redone original parser
= implemented original features
2021-04-27 11:49:07 +02:00
Erin 138b9efadc Added testing for base55, new identifier lexing 2021-04-27 11:09:19 +02:00
Erin 47400ee2ce Starting work on parser improvements
- Parser should parse single expressions
2021-04-26 10:44:42 +02:00
Erin 3e2dc5fba9 Added function/variable parsing
- Added block support
- TODO: Tidy it up
2021-04-18 22:33:55 +02:00