Tidying up after refactor.
authorTim Vaughan <tgvaughan@gmail.com>
Tue, 11 Oct 2016 09:11:56 +0000 (22:11 +1300)
committerTim Vaughan <tgvaughan@gmail.com>
Tue, 11 Oct 2016 09:11:56 +0000 (22:11 +1300)
src/forth.jl
src/lib.4th
src/lib_6_strings.4th

index 6afe492..a1a4799 100644 (file)
@@ -1243,7 +1243,9 @@ INCLUDED_CFA = defWord("INCLUDED",
     BRANCH_CFA, -14,                            # Loop
     SOURCE_ID_VAR_CFA, FETCH_CFA,
     CLOSE_FILE_CFA, DROP_CFA,                   # Close file
-    SOURCE_ID_VAR_CFA, STORE_CFA,                   # Restore input source
+    SOURCE_ID_VAR_CFA, STORE_CFA,               # Restore input source
+    LIT_CFA, 0, NUMIB_CFA, STORE_CFA,           # Zero #IB
+    LIT_CFA, 0, TOIN_CFA, STORE_CFA,            # Zero >IN
     EXIT_CFA])
 
 INCLUDE_CFA = defWord("INCLUDE", [LIT_CFA, 32, WORD_CFA,
index 60d7a56..86731cf 100644 (file)
@@ -15,3 +15,5 @@ include lib_7_variables.4th
 include lib_8_vocab.4th
 include lib_9_decompiler.4th
 include lib_10_misc.4th
+
+.(  done.) cr
index 56a2174..16d8001 100644 (file)
         0 ,             ( dummy length - we don't know what it is yet )
 
         BEGIN
-                >IN @ #IB @ >= IF      \ End of TIB?
+                >IN @ #IB @ >= IF      \ End of IB?
                         QUERY-INPUT    \ Get next line
                 THEN
 
-                IB >IN @ + @ 1 >IN +!  \ Get char from TIB
+                IB >IN @ + @ 1 >IN +!  \ Get char from IB
 
                 DUP [CHAR] " <>
         WHILE
   right-paren to the terminal. )
 : .( 
         BEGIN
-                >IN @ #IB @ >= IF      \ End of TIB?
+                >IN @ #IB @ >= IF      \ End of IB?
                         QUERY-INPUT    \ Get next line
                 THEN
 
-                IB >IN @ + @ 1 >IN +!  \ Get char from TIB
+                IB >IN @ + @ 1 >IN +!  \ Get char from IB
 
                 DUP [CHAR] ) = IF
                         DROP    ( drop the double quote character )