| Commit message (Collapse) | Author | Age |
|
|
|
|
|
| |
This is preferable to having the assembler crash with a stack overflow
error, because the user can now see which invocation caused the
overflow.
|
|
|
|
|
| |
This completes the Torque version 3 rewrite, other than some extensive
testing that is yet to be done.
|
|
|
|
|
|
|
|
| |
Massive improvement. Label references can be used anywhere in the
program, with the program being assembled repeatedly until all labels
have stabilised. The bytecode stage will just be a tiny stage tacked
onto the end, rather than the old bytecode stage that would resolve
labels and expressions.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a relaxation of the rule where a label reference could not
be used in any context that could change the length of an assembled
program.
We implement this in the bytecode stage by naively calculating an
initial address for each label as before. If a pinned address is
calculated from a label reference, some of the calculated addresses
could be incorrect. We then attempt to run the bytecode stage, which
will calculate a more accurate address for each label based on how
pinned addresses are calculated. If the address of any label was
changed by running this stage, we re-run the stage up to three more
times until all labels stabilise. If the labels fail to stabilise, we
return an error.
|
|
|
|
| |
torque-asm now uses the Compiler type provided by the assembler library.
|
|
|
|
|
|
|
|
|
|
|
|
| |
The language is now more general, the code is better structured, error
reporting is more detailed, and many new language features have
been implemented:
- conditional blocks
- first-class strings
- more expression operators
- binary literals
- negative values
- invocations in constant expressions
|
|
|