diff --git a/blk/001 b/blk/001 index 0d35d8c..c000d68 100644 --- a/blk/001 +++ b/blk/001 @@ -7,7 +7,7 @@ MASTER INDEX 200 Z80 assembler 260 Cross compilation 280 Z80 boot code 350 ACIA driver 370 SD Card driver 390 Cross-compiled core -428 Core words 480 AT28 Driver +439 Core words 480 AT28 Driver 490 TRS-80 Recipe 520 Fonts 550 TI-84+ Recipe diff --git a/blk/428 b/blk/428 deleted file mode 100644 index c42f756..0000000 --- a/blk/428 +++ /dev/null @@ -1,12 +0,0 @@ -Core words - -These words follow cross-compiled words, but unlike them, these -are self-bootstrapping and don't depend on the Cross Compiler. -They will typically be included in source form right after a -stage1 binary which will interpret it on boot and bootstrap -itself to a full intepreter, which can then be relinked with -the Relinker. There is no loader for these libraries because -you will typically XPACK (B267) them. - -430 core 442 fmt -447 readln 453 blk diff --git a/blk/430 b/blk/430 deleted file mode 100644 index 8fea4c3..0000000 --- a/blk/430 +++ /dev/null @@ -1,10 +0,0 @@ -: [ INTERPRET ; IMMEDIATE -: ] R> DROP ; -: LIT< WORD 34 , SCPY 0 C, ; IMMEDIATE -: LITA 36 , , ; -: ['] ' LITA ; IMMEDIATE -: COMPILE ' LITA ['] , , ; IMMEDIATE -: [COMPILE] ' , ; IMMEDIATE -: BEGIN H@ ; IMMEDIATE -: AGAIN COMPILE (br) H@ - , ; IMMEDIATE -: UNTIL COMPILE (?br) H@ - , ; IMMEDIATE diff --git a/blk/439 b/blk/439 index c2c4955..376b6de 100644 --- a/blk/439 +++ b/blk/439 @@ -1,12 +1,12 @@ -( Drop RSP until I-2 == INTERPRET. ) -: EXIT! - ['] INTERPRET ( I ) - BEGIN ( I ) - DUP ( I I ) - R> DROP I 2- @ ( I I a ) - = UNTIL - DROP -; -: (ok) SPC ." ok" NL ; -: (uflw) ABORT" stack underflow" ; -: (wnf) (print) SPC ABORT" word not found" ; +Core words + +These words follow cross-compiled words, but unlike them, these +are self-bootstrapping and don't depend on the Cross Compiler. +They will typically be included in source form right after a +stage1 binary which will interpret it on boot and bootstrap +itself to a full intepreter, which can then be relinked with +the Relinker. There is no loader for these libraries because +you will typically XPACK (B267) them. + +440 core 447 readln +453 blk diff --git a/blk/440 b/blk/440 index e69de29..8fea4c3 100644 --- a/blk/440 +++ b/blk/440 @@ -0,0 +1,10 @@ +: [ INTERPRET ; IMMEDIATE +: ] R> DROP ; +: LIT< WORD 34 , SCPY 0 C, ; IMMEDIATE +: LITA 36 , , ; +: ['] ' LITA ; IMMEDIATE +: COMPILE ' LITA ['] , , ; IMMEDIATE +: [COMPILE] ' , ; IMMEDIATE +: BEGIN H@ ; IMMEDIATE +: AGAIN COMPILE (br) H@ - , ; IMMEDIATE +: UNTIL COMPILE (?br) H@ - , ; IMMEDIATE diff --git a/blk/431 b/blk/441 similarity index 100% rename from blk/431 rename to blk/441 diff --git a/blk/432 b/blk/442 similarity index 100% rename from blk/432 rename to blk/442 diff --git a/blk/433 b/blk/443 similarity index 100% rename from blk/433 rename to blk/443 diff --git a/blk/434 b/blk/444 similarity index 100% rename from blk/434 rename to blk/444 diff --git a/blk/435 b/blk/445 similarity index 100% rename from blk/435 rename to blk/445 diff --git a/blk/446 b/blk/446 new file mode 100644 index 0000000..c2c4955 --- /dev/null +++ b/blk/446 @@ -0,0 +1,12 @@ +( Drop RSP until I-2 == INTERPRET. ) +: EXIT! + ['] INTERPRET ( I ) + BEGIN ( I ) + DUP ( I I ) + R> DROP I 2- @ ( I I a ) + = UNTIL + DROP +; +: (ok) SPC ." ok" NL ; +: (uflw) ABORT" stack underflow" ; +: (wnf) (print) SPC ABORT" word not found" ; diff --git a/emul/xcomp.fs b/emul/xcomp.fs index 6d93236..02d7251 100644 --- a/emul/xcomp.fs +++ b/emul/xcomp.fs @@ -21,7 +21,7 @@ CURRENT @ XCURRENT ! ( Update LATEST ) PC ORG @ 8 + ! ," CURRENT @ HERE ! " -430 459 XPACKR +440 459 XPACKR ," ' (key) 12 RAM+ ! " ORG @ 256 /MOD 2 PC! 2 PC! H@ 256 /MOD 2 PC! 2 PC! diff --git a/recipes/rc2014/xcomp.fs b/recipes/rc2014/xcomp.fs index d9ca5d6..b9301f2 100644 --- a/recipes/rc2014/xcomp.fs +++ b/recipes/rc2014/xcomp.fs @@ -27,7 +27,7 @@ CURRENT @ XCURRENT ! (entry) _ ( Update LATEST ) PC ORG @ 8 + ! -430 452 XPACKR ( core fmt readln ) +440 452 XPACKR ( core ) 123 132 XPACKR ( linker ) ," : _ ACIA$ RDLN$ (ok) ; _ " ORG @ 256 /MOD 2 PC! 2 PC! diff --git a/recipes/ti84/xcomp.fs b/recipes/ti84/xcomp.fs index 4351c2c..9652539 100644 --- a/recipes/ti84/xcomp.fs +++ b/recipes/ti84/xcomp.fs @@ -74,7 +74,7 @@ CREATE ~FNT CPFNT3x5 (entry) _ ( Update LATEST ) PC ORG @ 8 + ! -430 451 XPACKR ( core fmt readln ) +440 451 XPACKR ( core ) ," : _ LCD$ KBD$ (ok) RDLN$ ; _ " ORG @ 0x100 - 256 /MOD 2 PC! 2 PC! H@ 256 /MOD 2 PC! 2 PC! diff --git a/recipes/trs80/xcomp.fs b/recipes/trs80/xcomp.fs index efeda22..c55d982 100644 --- a/recipes/trs80/xcomp.fs +++ b/recipes/trs80/xcomp.fs @@ -21,7 +21,7 @@ CURRENT @ XCURRENT ! ( Update LATEST ) PC ORG @ 8 + ! ," CURRENT @ HERE ! " -430 459 XPACKR ( core readln fmt blk ) +440 459 XPACKR ( core ) 499 500 XPACKR ( trs80.fs ) ( 0x0a == NLPTR. TRS-80 wants CR-only newlines ) ," : _ ['] CR 0x0a RAM+ ! BLK$ FD$ (ok) RDLN$ ; _ "