1
0
mirror of https://github.com/hsoft/collapseos.git synced 2024-11-20 15:18:05 +11:00
collapseos/blk/450
Virgil Dupras f023f9bcb4 Pack core words blks a bit tighter
With all this recent movements, we had a bit of a fragmentation
issue.
2020-05-02 21:47:32 -04:00

17 lines
388 B
Plaintext

( Read one line in input buffer and make IN> point to it )
: (rdln)
(infl) BEGIN (rdlnc) NOT UNTIL
LF IN( IN> ! ;
( And finally, implement C<* )
: RDLN<
IN> @ C@
DUP IF ( not EOL? good, inc and return )
1 IN> +!
ELSE ( EOL ? readline. we still return null though )
(rdln)
THEN
( update C<? flag )
IN> @ C@ 0 > 0x06 RAM+ ! ( 06 == C<? )
;