From 5f425e48c5785d5523f5ad8eb3e362baeda90250 Mon Sep 17 00:00:00 2001
From: dos-reis <gdr@axiomatics.org>
Date: Sun, 26 Aug 2012 17:57:11 +0000
Subject: 	* interp/debug.lisp: Remove reference to TOK and CHR. 	*
 interp/spad-parser.boot: Likewise. 	* interp/g-error.boot: Likewise. 
 * interp/sys-globals.boot: Likewise. 	* interp/br-saturn.boot: Replace
 TERSYSCOMAND by 	terminateSystemCommand. 	*
 interp/i-syscmd.boot: Likewise. 	(terminateSystemCommand): Simplify. 
 * interp/spad.lisp (TERSYSCOMMAND): Remove.

---
 src/ChangeLog               | 12 ++++++++++++
 src/interp/br-saturn.boot   |  2 +-
 src/interp/debug.lisp       | 10 ++++------
 src/interp/g-error.boot     |  2 --
 src/interp/i-syscmd.boot    |  8 ++++----
 src/interp/msgdb.boot       |  1 -
 src/interp/spad-parser.boot |  1 -
 src/interp/spad.lisp        |  6 ------
 src/interp/sys-globals.boot |  5 -----
 9 files changed, 21 insertions(+), 26 deletions(-)

(limited to 'src')

diff --git a/src/ChangeLog b/src/ChangeLog
index 3a458968..c51f0c32 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,15 @@
+2012-08-26  Gabriel Dos Reis  <gdr@cs.tamu.edu>
+
+	* interp/debug.lisp: Remove reference to TOK and CHR.
+	* interp/spad-parser.boot: Likewise.
+	* interp/g-error.boot: Likewise.
+	* interp/sys-globals.boot: Likewise.
+	* interp/br-saturn.boot: Replace TERSYSCOMAND by
+	terminateSystemCommand.
+	* interp/i-syscmd.boot: Likewise.
+	(terminateSystemCommand): Simplify.
+	* interp/spad.lisp (TERSYSCOMMAND): Remove.
+
 2012-08-26  Gabriel Dos Reis  <gdr@cs.tamu.edu>
 
 	* include/sockio.h (init_purpose_table): Remove declaration.
diff --git a/src/interp/br-saturn.boot b/src/interp/br-saturn.boot
index 7a5c8c5d..c3172af8 100644
--- a/src/interp/br-saturn.boot
+++ b/src/interp/br-saturn.boot
@@ -1730,6 +1730,6 @@ purgeLocalLibdb() ==   --called by the user through a clear command?
 --  $newConlist: local := nil
 --  LOCALDATABASE(args,$options)
 --  extendLocalLibdb $newConlist
---  TERSYSCOMMAND()
+--  terminateSystemCommand()
 
 
diff --git a/src/interp/debug.lisp b/src/interp/debug.lisp
index bb7351e9..467716ac 100644
--- a/src/interp/debug.lisp
+++ b/src/interp/debug.lisp
@@ -57,8 +57,6 @@
 (DEFVAR /PRETTY () "controls pretty printing of trace output")
 (defparameter /ECHO NIL) ;;"prevents echo of SPAD or BOOT code with /c"
 (MAKEPROP 'LISP '/TERMCHR '(#\  #\())
-(MAKEPROP 'LSP '/TERMCHR '(#\  #\())
-(MAKEPROP 'META '/TERMCHR '(#\:  #\())
 (MAKEPROP 'INPUT '/TERMCHR '(#\:  #\<  #\  #\())
 (MAKEPROP 'SPAD '/TERMCHR '(#\:  #\<  #\  #\())
 (MAKEPROP 'BOOT '/TERMCHR '(#\:  #\<  #\  #\())
@@ -155,16 +153,16 @@
        (declare (special OUTPUTSTREAM))
   (PROG (FT oft SFN X EDINFILE FILE DEF KEY RECNO U W SOURCEFILES
          |$Echo| SINGLINEMODE INPUTSTREAM SPADERRORSTREAM
-         ISID NBLNK COMMENTCHR $TOKSTACK (/SOURCEFILES |$sourceFiles|)
+         ISID NBLNK COMMENTCHR (/SOURCEFILES |$sourceFiles|)
          METAKEYLST DEFINITION_NAME (|$sourceFileTypes| '(|spad| |boot| |lisp| |lsp| |meta|))
          ($FUNCTION FN) $NEWSPAD $LINESTACK $LINENUMBER STACK STACKX BACK OK
-         TRAPFLAG |$InteractiveMode| TOK COLUMN *QUERY CHR LINE
+         TRAPFLAG |$InteractiveMode| COLUMN *QUERY LINE
          (*COMP370-APPLY* (if (eq op 'define) #'eval-defun #'compile-defun)))
         (declare (special |$Echo| SINGLINEMODE INPUTSTREAM
-                     SPADERRORSTREAM ISID NBLNK COMMENTCHR $TOKSTACK /SOURCEFILES
+                     SPADERRORSTREAM ISID NBLNK COMMENTCHR /SOURCEFILES
                      METAKEYLST DEFINITION_NAME |$sourceFileTypes|
                      $FUNCTION $NEWSPAD $LINESTACK $LINENUMBER STACK STACKX BACK OK
-                     TRAPFLAG |$InteractiveMode| TOK COLUMN *QUERY CHR LINE))
+                     TRAPFLAG |$InteractiveMode| COLUMN *QUERY LINE))
         (if (CONSP FN) (SETQ FN (QCAR FN)))
         (SETQ INFILE (OR INFILE (|getFunctionSourceFile| FN)))
           ;; $FUNCTION is freely set in getFunctionSourceFile
diff --git a/src/interp/g-error.boot b/src/interp/g-error.boot
index f5e6d17d..d18f20ea 100644
--- a/src/interp/g-error.boot
+++ b/src/interp/g-error.boot
@@ -141,8 +141,6 @@ handleLispBreakLoop($BreakMode) ==
 TOP() == returnToTopLevel()
 
 returnToTopLevel() ==
-  SETQ(CHR, "ENDOFLINECHR")
-  SETQ(TOK, 'END__UNIT)
   THROW($intTopLevel,'restart)
 
 returnToReader() ==
diff --git a/src/interp/i-syscmd.boot b/src/interp/i-syscmd.boot
index 8170ccb0..9bf70aa3 100644
--- a/src/interp/i-syscmd.boot
+++ b/src/interp/i-syscmd.boot
@@ -161,7 +161,8 @@ selectOption(x,l,errorFunction) ==
   errorFunction => FUNCALL(errorFunction,x,u)
   nil
 
-terminateSystemCommand() == TERSYSCOMMAND()
+terminateSystemCommand() ==
+  spadThrow()
 
 commandUserLevelError(x,u) == userLevelErrorMessage("command",x,u)
 
@@ -1953,7 +1954,7 @@ library args ==
   LOCALDATABASE([STRING a for a in args],$options)
   extendLocalLibdb $newConlist
   changeDirectory origDir
-  TERSYSCOMMAND()
+  terminateSystemCommand()
 
 --% )quit
 
@@ -1970,7 +1971,7 @@ quitSpad2Cmd() ==
   x := UPCASE queryUserKeyedMsg("S2IZ0031",nil)
   STRING2ID_-N(x,1) in '(Y YES) => leaveScratchpad()
   sayKeyedMsg("S2IZ0032",nil)
-  TERSYSCOMMAND ()
+  terminateSystemCommand()
 
 leaveScratchpad () ==
   coreQuit() -- ??? should be coreQuit errorCount()
@@ -2745,7 +2746,6 @@ processSynonyms() ==
 --  $currentLine := strconc(fill,RPLACSTR(line, 1, # synstr, fun),opt)
   cl := strconc(fill,RPLACSTR(line, 1, # synstr, fun),opt)
   SETQ(LINE,cl)
-  SETQ(CHR,LINE.(p+1))
   processSynonyms ()
 
 -- functions for interfacing to system commands from algebra code
diff --git a/src/interp/msgdb.boot b/src/interp/msgdb.boot
index 052afa9d..c4182b85 100644
--- a/src/interp/msgdb.boot
+++ b/src/interp/msgdb.boot
@@ -585,7 +585,6 @@ spadStartUpMsgs() ==
   sayKeyedMsg("S2GL0018D",nil)
   sayKeyedMsg("S2GL0003B",[$opSysName])
   sayMSG bar
-  sayMSG " "
 
 HELP() == sayKeyedMsg("S2GL0019",nil)
 
diff --git a/src/interp/spad-parser.boot b/src/interp/spad-parser.boot
index 7ce0fb01..d4f27573 100644
--- a/src/interp/spad-parser.boot
+++ b/src/interp/spad-parser.boot
@@ -52,7 +52,6 @@ module spad_-parser where
 --%
 
 $SKIPME := false
-TOK := nil
 DEFINITION__NAME := nil
 $preparseLastLine := nil
 $preparseReportIfTrue := false
diff --git a/src/interp/spad.lisp b/src/interp/spad.lisp
index d3c0bd3c..fd101237 100644
--- a/src/interp/spad.lisp
+++ b/src/interp/spad.lisp
@@ -111,12 +111,6 @@
 ;         SYSTEM COMMANDS
 ;************************************************************************
 
-(defun TERSYSCOMMAND ()
-  (FRESH-LINE)
-  (SETQ CHR 'ENDOFLINECHR)
-  (SETQ TOK 'END_UNIT)
-  (|spadThrow|))
-
 (defun /READ (L Q)
   (SETQ |$editFile| L)
   (COND
diff --git a/src/interp/sys-globals.boot b/src/interp/sys-globals.boot
index 04821f54..bcd26271 100644
--- a/src/interp/sys-globals.boot
+++ b/src/interp/sys-globals.boot
@@ -199,9 +199,6 @@ $topOp := nil
 ++
 $streamCount := 0
 
-++
-$TOKSTACK := nil
-
 ++
 $FUNCTION := nil
 
@@ -327,8 +324,6 @@ _/WSNAME := "NOBOOT"
 
 ++
 LINE := nil
-CHR := nil
-TOK := nil
 
 $Echo := false
 
-- 
cgit v1.2.3