2020-04-25 21:54:07 -04:00
|
|
|
: ELSE ( a1 -- a2 | a1: IF cell a2: ELSE cell )
|
|
|
|
COMPILE (br)
|
|
|
|
2 ALLOT
|
|
|
|
DUP H@ -^ SWAP ( a-H a )
|
|
|
|
!
|
|
|
|
H@ 2- ( push a. -2 for allot offset )
|
|
|
|
; IMMEDIATE
|
|
|
|
|
2020-04-28 08:28:59 -04:00
|
|
|
: [IF]
|
|
|
|
IF EXIT THEN
|
|
|
|
LIT< [THEN] BEGIN DUP WORD S= UNTIL DROP ;
|
|
|
|
: [THEN] ;
|