correctly handle [register]s as operands
This commit is contained in:
@@ -306,8 +306,8 @@ supported tokens are listed below
|
||||
| cr8 | 0x004E | |
|
||||
| hlt | 0x004F | |
|
||||
| int3 | 0x0050 | |
|
||||
| [ | 0x0051 | open bracket placeholder; 0x10XX should be used in contexts where the surrounding tokens can be known |
|
||||
| ] | 0x0052 | |
|
||||
| | 0x0051 | deprecated; formerly `[`. Now `0x10XX` is used. |
|
||||
| | 0x0052 | deprecated; formerly `]`. |
|
||||
| xor | 0x0053 | |
|
||||
| inc | 0x0054 | |
|
||||
| dec | 0x0055 | |
|
||||
@@ -323,14 +323,15 @@ supported tokens are listed below
|
||||
| jg | 0x005F | |
|
||||
| jle | 0x0060 | |
|
||||
| jl | 0x0061 | |
|
||||
| + | 0x0062 | |
|
||||
| - | 0x0063 | |
|
||||
| * | 0x0064 | |
|
||||
| / | 0x0065 | |
|
||||
| [ | 0x10XX | open bracket with `XX` bytes until the closing bracket |
|
||||
| | 0xFEXX | token terminator byte as token, where `XX` is the byte |
|
||||
| | 0x10XX | some memory address; `XX` is as specified below |
|
||||
| | 0xFFFF | unrecognised token |
|
||||
|
||||
values of `XX` in `0x10XX`:
|
||||
|
||||
| XX | description |
|
||||
|------|-------------|
|
||||
| 0x00 | following byte is the token ID of some register |
|
||||
|
||||
### example program
|
||||
|
||||
#### program in assembly
|
||||
|
||||
Reference in New Issue
Block a user