fix some references to the old end instruction (now called halt)
FossilOrigin-Name: 9ec683cd989ae9f7186047422149200d256146cb68bf0f273e702054fcfae3c0
This commit is contained in:
parent
12f0f4f4e1
commit
d696221f2a
4 changed files with 6 additions and 16 deletions
|
@ -26,7 +26,7 @@ instruction name. For a non operation, use '..' instead of
|
|||
2 dup 9 ccall 16 store 23 xor
|
||||
3 drop 10 return 17 add 24 shift
|
||||
4 swap 11 eq 18 sub 25 zret
|
||||
5 push 12 neq 19 mul 26 end
|
||||
5 push 12 neq 19 mul 26 halt
|
||||
6 pop 13 lt 20 divmod 27 ienum
|
||||
|
||||
E.g., for a sequence of dup, multiply, no-op, drop:
|
||||
|
@ -178,7 +178,7 @@ int32_t opcode_for(char *s) {
|
|||
if (strcmp(s, "di") == 0) return 20; if (strcmp(s, "an") == 0) return 21;
|
||||
if (strcmp(s, "or") == 0) return 22; if (strcmp(s, "xo") == 0) return 23;
|
||||
if (strcmp(s, "sh") == 0) return 24; if (strcmp(s, "zr") == 0) return 25;
|
||||
if (strcmp(s, "en") == 0) return 26; if (strcmp(s, "ie") == 0) return 27;
|
||||
if (strcmp(s, "ha") == 0) return 26; if (strcmp(s, "ie") == 0) return 27;
|
||||
if (strcmp(s, "iq") == 0) return 28; if (strcmp(s, "ii") == 0) return 29;
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -3473,7 +3473,7 @@ for return addresses.
|
|||
| 23 | xo | bitwise xor | xy-n | - |
|
||||
| 24 | sh | shift | xy-n | - |
|
||||
| 25 | zr | zero return | n-? | - |
|
||||
| 26 | en | end | - | - |
|
||||
| 26 | ha | halt | - | - |
|
||||
| 27 | ie | i/o enumerate | -n | - |
|
||||
| 28 | iq | i/o query | n-xy | - |
|
||||
| 29 | ii | i/o invoke | ...n- | - |
|
||||
|
@ -3587,11 +3587,6 @@ The currently supported and reserved device identifiers are:
|
|||
This list may be revised in the future. The only guaranteed
|
||||
stable indentifier is 0000 for generic output.
|
||||
|
||||
## Trivia
|
||||
|
||||
There are 810,000 possible combinations of instructions. Only
|
||||
73 are used in the implementation of RETRO.
|
||||
|
||||
# Internals: Interface Layers
|
||||
|
||||
Nga provides a virtual processor and an extensible way of adding
|
||||
|
|
|
@ -40,7 +40,7 @@ for return addresses.
|
|||
| 23 | xo | bitwise xor | xy-n | - |
|
||||
| 24 | sh | shift | xy-n | - |
|
||||
| 25 | zr | zero return | n-? | - |
|
||||
| 26 | en | end | - | - |
|
||||
| 26 | ha | halt | - | - |
|
||||
| 27 | ie | i/o enumerate | -n | - |
|
||||
| 28 | iq | i/o query | n-xy | - |
|
||||
| 29 | ii | i/o invoke | ...n- | - |
|
||||
|
@ -153,8 +153,3 @@ The currently supported and reserved device identifiers are:
|
|||
|
||||
This list may be revised in the future. The only guaranteed
|
||||
stable indentifier is 0000 for generic output.
|
||||
|
||||
## Trivia
|
||||
|
||||
There are 810,000 possible combinations of instructions. Only
|
||||
73 are used in the implementation of RETRO.
|
||||
|
|
|
@ -55,7 +55,7 @@ the token type and use `span`.
|
|||
(tokens_with_prefixes)
|
||||
dup fetch
|
||||
$: [ 'colon span ] case
|
||||
$( [ 'comment span ] case
|
||||
$( [ 'note span ] case
|
||||
$' [ 'str span ] case
|
||||
$# [ 'num span ] case
|
||||
$. [ 'fnum span ] case
|
||||
|
@ -125,7 +125,7 @@ And finally, run it.
|
|||
span { white-space: pre }
|
||||
.text { color: #c5c8c6; white-space: pre }
|
||||
.colon { color: #cc6666; }
|
||||
.comment { color: #969896; }
|
||||
.note { color: #969896; }
|
||||
.str { color: #f0c674; }
|
||||
.num { color: #8abeb7; }
|
||||
.fnum { color: #8abeb7; font-weight: bold; }
|
||||
|
|
Loading…
Reference in a new issue