Commit Graph
34 Commits
Author SHA1 Message Date
raymon 756e21e7fd Remove field is_allocated from MemCell 2022-01-05 12:58:49 +01:00
raymon bb63782711 Implement pointm 2022-01-05 12:26:27 +01:00
raymon 0ac4731f8a Implement point 2022-01-05 12:26:17 +01:00
raymon 1673690956 Implement delvar 2022-01-04 23:25:10 +01:00
raymon 189a57f884 Panic on duplicate variable creation 2022-01-04 10:18:53 +01:00
raymon df38c66d83 Implement var 2022-01-04 10:02:47 +01:00
raymon 5e2497b2ad Fill-in struct fields 2022-01-04 10:02:47 +01:00
raymon e712f40738 Pass state to instruct
state will store:
- variable positions
2022-01-02 20:25:12 +01:00
raymon 2ac2306b95 Allow newlines between comments and statements 2022-01-01 18:40:15 +01:00
raymon 9cad628caf Cleanup grammar file
- Formatting
- Remove generic `operator` and `operand`
  - used for testing
2022-01-01 18:31:06 +01:00
raymon 0a03cfa416 Match macro #include 2022-01-01 18:29:00 +01:00
raymon c868b5f052 Explicitly allow spacing before loopBlockEnd
- Inherited prefixed `spacing*` only applied to loopBlockStart,
- as the rule from statement only allowed spacing before the entire loopBlock
2022-01-01 17:33:35 +01:00
raymon 53d712db4f Allow most common word separators for variables
- Also includes '?' suffix for bools
2021-12-31 09:24:14 +01:00
raymon d0805b55a7 Correct example.mblf with no-arg print 2021-12-30 23:29:00 +01:00
raymon 42c45c3835 Extend numeric operations to constant operations
- Besides decNums and hexNums, characters are also valid
2021-12-30 23:27:30 +01:00
raymon 5c450b2c6a Match all instructions without arguments 2021-12-30 22:47:16 +01:00
raymon c56770d604 Match all instructions with number argument 2021-12-30 22:46:04 +01:00
raymon 29ed49b554 Print other Rules to stdout
- Entire parsed file in readable form to stdout
2021-12-30 14:28:08 +01:00
raymon 974c6b8021 Match all instructions with variable argument 2021-12-30 14:28:08 +01:00
raymon e3883f2ae2 Use built-in NEWLINE Rule 2021-12-26 20:41:59 +01:00
raymon 02b392d96e Allow extra newlines between statements 2021-12-26 20:38:31 +01:00
raymon 629580e628 Allow comments on their own line 2021-12-26 20:22:07 +01:00
raymon a381e148f0 Allow indented statements 2021-12-26 20:22:07 +01:00
raymon 298513eb7f Allow either spaces or tabs as spacing 2021-12-26 19:47:40 +01:00
raymon 6eb61ad83d Extract newline grammar rule 2021-12-26 19:47:25 +01:00
raymon 91a4c8c0b8 Enforce newlines around body of loopBlock
- The start and end of the loopBlock should be on their own line
2021-12-26 19:42:53 +01:00
raymon bc99a9d96b Ensure operand is optional: only 0 or 1 2021-12-26 19:31:06 +01:00
raymon 9fbf521174 Allow nested loopBlocks
- loopBlocks now contain statements i.o. instructions
2021-12-26 19:23:37 +01:00
raymon 6804d2aac3 Extract IO out of instruct
- Attach fail case only once on main
2021-10-20 21:46:19 +02:00
raymon d0d82f1831 Formatting 2021-10-20 21:21:25 +02:00
raymon e20cfcbb4a Parse till operators 2021-10-20 21:21:02 +02:00
raymon 0a157cf02e Start with Pest Parser 2021-10-19 12:19:08 +02:00
raymon 389364a2dc Add CLI
- takes input-file, copies to output-file
2021-09-29 11:05:57 +02:00
raymon 805c7f5dd2 Init 2021-09-29 11:03:59 +02:00