forth: add word "LITS"
This commit is contained in:
parent
145fdd8e05
commit
def4ebd7ea
@ -145,6 +145,7 @@ NOT f -- f Push the logical opposite of f
|
|||||||
*** Strings ***
|
*** Strings ***
|
||||||
LIT< x -- Read following word and write to HERE as a string
|
LIT< x -- Read following word and write to HERE as a string
|
||||||
literal.
|
literal.
|
||||||
|
LITS a -- Write word at addr a as a atring literal.
|
||||||
SCMP a1 a2 -- n Compare strings a1 and a2. See CMP
|
SCMP a1 a2 -- n Compare strings a1 and a2. See CMP
|
||||||
SLEN a -- n Push length of str at a.
|
SLEN a -- n Push length of str at a.
|
||||||
|
|
||||||
|
@ -988,16 +988,15 @@ LITN:
|
|||||||
ld (HERE), hl
|
ld (HERE), hl
|
||||||
jp next
|
jp next
|
||||||
|
|
||||||
.db "LIT<"
|
.db "LITS"
|
||||||
.fill 3
|
.fill 3
|
||||||
.dw LITN
|
.dw LITN
|
||||||
.db 1 ; IMMEDIATE
|
.db 1 ; IMMEDIATE
|
||||||
LITRD:
|
LITS:
|
||||||
.dw compiledWord
|
.dw compiledWord
|
||||||
.dw NUMBER
|
.dw NUMBER
|
||||||
.dw LIT
|
.dw LIT
|
||||||
.dw WR
|
.dw WR
|
||||||
.dw WORD
|
|
||||||
.dw .scpy
|
.dw .scpy
|
||||||
.dw EXIT
|
.dw EXIT
|
||||||
|
|
||||||
@ -1010,6 +1009,16 @@ LITRD:
|
|||||||
jp next
|
jp next
|
||||||
|
|
||||||
|
|
||||||
|
.db "LIT<"
|
||||||
|
.fill 3
|
||||||
|
.dw LITS
|
||||||
|
.db 1 ; IMMEDIATE
|
||||||
|
LITRD:
|
||||||
|
.dw compiledWord
|
||||||
|
.dw WORD
|
||||||
|
.dw LITS
|
||||||
|
.dw EXIT
|
||||||
|
|
||||||
.db "(find)"
|
.db "(find)"
|
||||||
.fill 1
|
.fill 1
|
||||||
.dw LITRD
|
.dw LITRD
|
||||||
|
Loading…
Reference in New Issue
Block a user