1
0
mirror of https://github.com/hsoft/collapseos.git synced 2024-11-27 19:38:06 +11:00
collapseos/blk/130

17 lines
640 B
Plaintext
Raw Normal View History

: RLDICT ( target offset -- )
H@ 2+ ! H@ ! ( H@+2 == offset, H@ == target )
H@ @ WORD( DUP H@ -^ ( src u )
DUP ROT SWAP H@ 4 + ( u src u dst )
SWAP MOVE ( u )
4 + DUP CURRENT @ WORD( + ( u we )
2020-05-04 22:10:18 +10:00
DUP .X NL
SWAP CURRENT @ PREV + DUP .X NL ( we wr )
BEGIN ( we wr )
DUP ROT ( wr wr we )
H@ @ H@ 2+ @ ( wr wr we ol o )
2SWAP RLWORD ( wr )
DUP PREV SWAP ( wr oldwr )
WORD( SWAP ( we wr )
DUP 4 - H@ <= ( are we finished? )
2020-05-04 22:10:18 +10:00
UNTIL H@ 4 + .X NL ;