1
0
mirror of https://github.com/hsoft/collapseos.git synced 2024-12-28 13:38:06 +11:00
collapseos/blk/268
Virgil Dupras b760c2d353 SCPY: don't copy the NULL
This makes [entry] much simpler. Also, remove unused LITS word.
2020-05-12 07:36:20 -04:00

17 lines
378 B
Plaintext

: XPACK ( blkno -- )
BLK@
BLK( 0x2e RAM+ ! ( boot ptr )
['] (boot<) 0x08 RAM+ ! ( C<* override )
BEGIN
WORD
0x2e RAM+ @ BLK( 1024 + < IF
DUP LIT< ( S= IF
DROP [COMPILE] (
ELSE
SCPY 0x20 C,
THEN 0 ( loop again )
ELSE 1 ( stop looping ) THEN
UNTIL
0 0x08 RAM+ !
;