X-Git-Url: https://git.kengrimes.com/?p=watForth.git;a=blobdiff_plain;f=forth.forth;h=e7dc22974c155f5366adf97e19e9d52b049b4446;hp=2facfc94d183277c66e2bb0ae14d880d4d57202b;hb=d30761f3974c9a6ccc543392c20060885ca91a36;hpb=0096f7eba3c6c1584234866ee3cbfe5b1df765c2 diff --git a/forth.forth b/forth.forth index 2facfc9..e7dc229 100644 --- a/forth.forth +++ b/forth.forth @@ -1,2 +1,28 @@ -: dothings ^C dup + ; ^E -5 dothings . +\ This program is free software: you can redistribute it and/or modify +\ it under the terms of the GNU General Public License as published by +\ the Free Software Foundation, either version 3 of the License, or +\ (at your option) any later version. +\ +\ This program is distributed in the hope that it will be useful, +\ but WITHOUT ANY WARRANTY; without even the implied warranty of +\ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +\ GNU General Public License for more details. +\ +\ You should have received a copy of the GNU General Public License +\ along with this program. If not, see . +word ' here define +word word find , word find find , word ; find , +word : here define +' word , ' here , ' define , ' ; , +: IWRITE-MODE ' dup , ' JNZ: , here 12 + , ' 2drop , ' ; , +' 2dup , ' find , ' dup , ' JZ: , here 16 + , ' , , ' 2drop , ' ; , +' drop , ' LIT , ' LIT , ' , , 16720 , ' , , ' ; , +: i ' LIT , ' MODE , ' LIT , ' IWRITE-MODE , ' ! , ' ; , +: e ' LIT , ' MODE , ' LIT , ' EXECUTE-MODE , ' ! , ' ; , +\i +\: FINISH-STRING DROP STRING-END ; +\: " STRING-START +\: KEYPUMP KEY 34 =? JNZ: FINISH-STRING STRING-PUT JMP: KEYPUMP +\e +" watForth-32 Interactive CLI: +" .s