diff options
author | dos-reis <gdr@axiomatics.org> | 2011-07-04 16:40:44 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2011-07-04 16:40:44 +0000 |
commit | 1a18d7b2e1b3796f6dc360e3bae0a57616aa497c (patch) | |
tree | 48b98145ec77b1a52b3eb1add288191767fa8a4b /src/interp | |
parent | 2f5255f62b85b026dcf11adafff07ac2f254a41c (diff) | |
download | open-axiom-1a18d7b2e1b3796f6dc360e3bae0a57616aa497c.tar.gz |
* interp/setvars.boot: Remove support for script formula.
* interp/setvart.boot: Likewise.
* interp/diagnostics.boot (sayBrightlyNT1): Move from macros.lisp.
(sayBrightly1): Likewise.
(sayBrightlyNT): Likewise.
(sayBrightly): Likewise.
(sayBrightlyI): Likewise.
(sayMSG): Likewise.
(sayTeX): Likewise.
(sayMSG2File): Likewise.
* interp/i-output.boot (formulaFormat): Remove.
(output): Adjust.
* interp/macros.lisp (sayMSGNT): Remove.
(sayFORTRAN): Likewise.
(sayFORMULA): Likewise.
($formulaOutputstream): Likewise.
* interp/sys-globals.boot ($formulaOutputstream): Remove.
* interp/spad.lisp ($formulaFormat): Remove.
* algebra/exposed.lsp.pamphlet: Do not expose ScriptFormulaFormat
and ScriptFormulaFormat1.
* algebra/exposed.lsp.pamphlet: Remove.
Diffstat (limited to 'src/interp')
-rw-r--r-- | src/interp/c-doc.boot | 4 | ||||
-rw-r--r-- | src/interp/category.boot | 6 | ||||
-rw-r--r-- | src/interp/diagnostics.boot | 43 | ||||
-rw-r--r-- | src/interp/i-output.boot | 11 | ||||
-rw-r--r-- | src/interp/macros.lisp | 71 | ||||
-rw-r--r-- | src/interp/setvars.boot | 113 | ||||
-rw-r--r-- | src/interp/setvart.boot | 50 | ||||
-rw-r--r-- | src/interp/spad.lisp | 1 | ||||
-rw-r--r-- | src/interp/sys-globals.boot | 3 |
9 files changed, 48 insertions, 254 deletions
diff --git a/src/interp/c-doc.boot b/src/interp/c-doc.boot index 19ab4bd4..cfcd96a9 100644 --- a/src/interp/c-doc.boot +++ b/src/interp/c-doc.boot @@ -1272,11 +1272,11 @@ checkDocError u == $constructorName => checkDocMessage u u if $exposeFlag and $exposeFlagHeading then - SAYBRIGHTLY1($exposeFlagHeading,$outStream) + sayBrightly1($exposeFlagHeading,$outStream) sayBrightly $exposeFlagHeading $exposeFlagHeading := nil sayBrightly msg - if $exposeFlag then SAYBRIGHTLY1(msg,$outStream) + if $exposeFlag then sayBrightly1(msg,$outStream) --if called by checkDocFile (see file checkdoc.boot) ++ Augment `u' with information about the owner of the source file diff --git a/src/interp/category.boot b/src/interp/category.boot index 6407fca9..53079f37 100644 --- a/src/interp/category.boot +++ b/src/interp/category.boot @@ -296,7 +296,7 @@ PredImplies(a,b) == SigListOpSubsume([[name1,sig1,:.],:.],list) == --does m subsume another operator in the list? - --see "operator subsumption" in SYSTEM SCRIPT + --see "operator subsumption" in JHD's report --if it does, returns the subsumed member lsig1 := #sig1 ans := [] @@ -305,7 +305,7 @@ SigListOpSubsume([[name1,sig1,:.],:.],list) == return ans MachineLevelSubsume([name1,[out1,:in1],:flag1],[name2,[out2,:in2],:flag2]) == - -- Checks for machine-level subsumption in the sense of SYSTEM SCRIPT + -- Checks for machine-level subsumption -- true if the first signature subsumes the second -- flag1 = flag2 and: this really should be checked, but symbolEq?(name1,name2) and MachineLevelSubset(out1,out2) and @@ -442,7 +442,7 @@ JoinInner(l,$e) == -- this skips buggy code which discards needed categories for [b,condition] in FindFundAncs l' repeat --This loop implements Category Subsumption - --as described in SYSTEM SCRIPT + --as described in JHD's report if not (b.0=nil) then --It's a named category bname:= b.0 diff --git a/src/interp/diagnostics.boot b/src/interp/diagnostics.boot index fd5c5e09..a16cba91 100644 --- a/src/interp/diagnostics.boot +++ b/src/interp/diagnostics.boot @@ -97,3 +97,46 @@ MESSAGEPRINT_-2 x == MESSAGEPRINT_-1 first x MESSAGEPRINT_-2 rest x +--% + +++ if not nil, gives stream for sayBrightly output +$sayBrightlyStream := nil + +sayBrightlyNT1(x,out) == + cons? x => brightPrint(x,out) + brightPrint0(x,out) + +sayBrightly1(x,out) == + sayBrightlyNT1(x,out) + finishLine out + +sayBrightlyNT(x,out == $OutputStream) == + x = nil => nil + $sayBrightlyStream ~= nil => sayBrightlyNT1(x,$sayBrightlyStream) + IS_-CONSOLE out => sayBrightlyNT1(x,out) + sayBrightly1(x,out) => sayBrightlyNT1(x,out) + nil + +sayBrightly(x,out == $OutputStream) == + x = nil => nil + $sayBrightlyStream ~= nil => sayBrightly1(x,$sayBrightlyStream) + IS_-CONSOLE out => sayBrightly1(x,out) + sayBrightly1(x,out) => sayBrightly1(x,$OutputStream) + nil + +sayBrightlyI(x,out == $OutputStream) == + x = nil => nil + sayBrightly1(x,out) + +sayMSG x == + x = nil => nil + sayBrightly1(x,$algebraOutputStream) + +sayMSG2File msg == + file := makePathname('spadmsg,'listing,$listingDirectory) + str := DEFIOSTREAM(['(MODE . OUTPUT),['FILE,:file]],255,0) + sayBrightly1(msg,str) + +sayTeX x == + x = nil => nil + sayBrightly1(x,$texOutputStream) diff --git a/src/interp/i-output.boot b/src/interp/i-output.boot index f79112b2..56f164a2 100644 --- a/src/interp/i-output.boot +++ b/src/interp/i-output.boot @@ -1524,15 +1524,6 @@ spadPrint(x,m) == output(x,m) newlineIfDisplaying() -formulaFormat expr == - sff := '(ScriptFormulaFormat) - formatFn := getFunctionFromDomain("coerce",sff,[$OutputForm]) - displayFn := getFunctionFromDomain("display",sff,[sff]) - SPADCALL(SPADCALL(expr,formatFn),displayFn) - if not $collectOutput then - finishLine $algebraOutputStream - nil - texFormat expr == tf := $TexFormat formatFn := @@ -1562,7 +1553,6 @@ mathmlFormat expr == output(expr,domain) == if isWrapped expr then expr := unwrap expr isMapExpr expr => - if $formulaFormat then formulaFormat expr if $texFormat then texFormat expr if $mathmlFormat then mathmlFormat expr if $algebraFormat then mathprintWithNumber(expr,domain) @@ -1573,7 +1563,6 @@ output(expr,domain) == texFormat outputDomainConstructor expr T := coerceInteractive(objNewWrap(expr,domain),$OutputForm) => x := objValUnwrap T - if $formulaFormat then formulaFormat x if $fortranFormat then dispfortexp x if not $collectOutput then diff --git a/src/interp/macros.lisp b/src/interp/macros.lisp index 13018ade..3793de79 100644 --- a/src/interp/macros.lisp +++ b/src/interp/macros.lisp @@ -326,77 +326,6 @@ ((stringp x) x) ((write-to-string x)))) -(defun |sayTeX| (x) - (if (null x) - nil - (sayBrightly1 x |$texOutputStream|))) - -(defvar |$sayBrightlyStream| nil "if not nil, gives stream for sayBrightly output") - -(defun |sayBrightly| (x &optional (out-stream |$OutputStream|)) - (COND ((NULL X) NIL) - (|$sayBrightlyStream| - (sayBrightly1 X |$sayBrightlyStream|)) - ((IS-CONSOLE out-stream) - (sayBrightly1 X out-stream)) - ((sayBrightly1 X out-stream) - (sayBrightly1 X |$OutputStream|)))) - -(defun |sayBrightlyI| (x &optional (s |$OutputStream|)) - "Prints at console or output stream." - (if (NULL X) NIL (sayBrightly1 X S))) - -(defun |sayBrightlyNT| (x &optional (S |$OutputStream|)) - (COND ((NULL X) NIL) - (|$sayBrightlyStream| - (sayBrightlyNT1 X |$sayBrightlyStream|)) - ((IS-CONSOLE S) - (sayBrightlyNT1 X S)) - ((sayBrightly1 X S) - (sayBrightlyNT1 X |$OutputStream|)))) - -(defun sayBrightlyNT1 (X out) - (if (ATOM X) - (|brightPrint0| X out) - (|brightPrint| X out))) - -(defun sayBrightly1 (X out) - (if (ATOM X) - (progn - (|brightPrint0| X out) - (TERPRI out) - (force-output out)) - (progn - (|brightPrint| X out) - (TERPRI out) - (force-output out)))) - -(defun |sayMSG| (X) - (if (NULL X) NIL (sayBrightly1 X |$algebraOutputStream|))) - -(defun |sayMSGNT| (X) - (if (NULL X) NIL (sayBrightlyNT1 X |$algebraOutputStream|))) - -(defun |sayMSG2File| (msg) - (PROG (file str) - (SETQ file (|makePathname| '|spadmsg| '|listing| |$listingDirectory|)) - (SETQ str - (DEFIOSTREAM - (CONS '(MODE . OUTPUT) (CONS (CONS 'FILE file) NIL)) - 255 0)) - (sayBrightly1 msg str) - (SHUT str) ) ) - -(defvar |$fortranOutputStream|) - -(defun |sayFORTRAN| (x) "Prints on Fortran output stream." - (if (NULL X) NIL (sayBrightly1 X |$fortranOutputStream|))) - -(defvar |$formulaOutputStream|) - -(defun |sayFORMULA| (X) "Prints on formula output stream." - (if (NULL X) NIL (sayBrightly1 X |$formulaOutputStream|))) - ;; the following are redefined in MSGDB BOOT (DEFUN BLANKS (N &optional (stream |$OutputStream|)) diff --git a/src/interp/setvars.boot b/src/interp/setvars.boot index 561793c3..4b459db5 100644 --- a/src/interp/setvars.boot +++ b/src/interp/setvars.boot @@ -1464,119 +1464,6 @@ describeSetOutputOpenMath() == '"the one you set with the )cd system command.",'%l,_ '"The current setting is: ",'%b,setOutputOpenMath "%display%",'%d] --- See the subsection output script in setvart.boot --- --- ---------------------- The script Option ---------------------- - --- Description: display output in SCRIPT formula format - --- )set output script is used to tell AXIOM to turn IBM Script --- formula-style output printing on and off, and where to place --- the output. By default, the destination for the output is the --- screen but printing is turned off. - --- Syntax: )set output script <arg> --- where arg can be one of --- on turn IBM Script formula printing on --- off turn IBM Script formula printing off --- (default state) --- console send IBM Script formula output to screen --- (default state) --- fp<.fe> send IBM Script formula output to file with file --- prefix fp and file extension .fe. If not given, --- .fe defaults to .sform. - --- If you wish to send the output to a file, you must issue --- this command twice: once with on and once with the file --- name. For example, to send IBM Script formula output to --- the file polymer.sform, issue the two commands - --- )set output script on --- )set output script polymer - --- The output is placed in the directory from which you --- invoked AXIOM or the one you set with the )cd system command. --- The current setting is: Off:CONSOLE --- - - -setOutputFormula arg == - arg = "%initialize%" => - $formulaOutputStream := - DEFIOSTREAM('((MODE . OUTPUT) (DEVICE . CONSOLE)),255,0) - $formulaOutputFile := '"CONSOLE" - $formulaFormat := nil - - arg = "%display%" => - if $formulaFormat then label := '"On:" else label := '"Off:" - strconc(label,$formulaOutputFile) - - (null arg) or (arg = "%describe%") or (first arg = '_?) => - describeSetOutputFormula() - - -- try to figure out what the argument is - - if arg is [fn] and - fn in '(Y N YE YES NO O ON OF OFF CONSOLE y n ye yes no o on of off console) - then 'ok - else arg := [fn,'sform] - - arg is [fn] => - UPCASE(fn) in '(Y N YE O OF) => - sayKeyedMsg("S2IV0002",'(script script)) - UPCASE(fn) in '(NO OFF) => $formulaFormat := nil - UPCASE(fn) in '(YES ON) => $formulaFormat := true - UPCASE(fn) = 'CONSOLE => - SHUT $formulaOutputStream - $formulaOutputStream := - DEFIOSTREAM('((MODE . OUTPUT) (DEVICE . CONSOLE)),255,0) - $formulaOutputFile := '"CONSOLE" - - (arg is [fn,ft]) or (arg is [fn,ft,fm]) => -- aha, a file - if (ptype := pathnameType fn) then - fn := strconc(pathnameDirectory fn,pathnameName fn) - ft := ptype - if null fm then fm := 'A - filename := $FILEP(fn,ft,fm) - null filename => - sayKeyedMsg("S2IV0003",[fn,ft,fm]) - (testStream := MAKE_-OUTSTREAM(filename,255,0)) => - SHUT $formulaOutputStream - $formulaOutputStream := testStream - $formulaOutputFile := object2String filename - sayKeyedMsg("S2IV0004",['"IBM Script formula",$formulaOutputFile]) - sayKeyedMsg("S2IV0003",[fn,ft,fm]) - - sayKeyedMsg("S2IV0005",nil) - describeSetOutputFormula() - - -describeSetOutputFormula() == - sayBrightly ['%b,'")set output script",'%d,_ - '"is used to tell AXIOM to turn IBM Script formula-style",'%l,_ - '"output printing on and off, and where to place the output. By default, the",'%l,_ - '"destination for the output is the screen but printing is turned off.",'%l,_ - '%l,_ - '"Syntax: )set output script <arg>",'%l,_ - '" where arg can be one of",'%l,_ - '" on turn IBM Script formula printing on",'%l,_ - '" off turn IBM Script formula printing off (default state)",'%l,_ - '" console send IBM Script formula output to screen (default state)",'%l,_ - '" fp<.fe> send IBM Script formula output to file with file prefix fp",'%l,_ - '" and file extension .fe. If not given, .fe defaults to .sform.",'%l, - '%l,_ - '"If you wish to send the output to a file, you must issue this command",'%l,_ - '"twice: once with",'%b,'"on",'%d,'"and once with the file name. For example, to send",'%l,_ - '"IBM Script formula output to the file",'%b,'"polymer.sform,",'%d,'"issue the two commands",'%l,_ - '%l,_ - '" )set output script on",'%l,_ - '" )set output script polymer",'%l,_ - '%l,_ - '"The output is placed in the directory from which you invoked AXIOM or",'%l,_ - '"the one you set with the )cd system command.",'%l,_ - '"The current setting is: ",'%b,setOutputFormula "%display%",'%d] - - -- See the section tex in setvart.boot -- -- ----------------------- The tex Option ------------------------ diff --git a/src/interp/setvart.boot b/src/interp/setvart.boot index 0b1ff0d0..c19f8688 100644 --- a/src/interp/setvart.boot +++ b/src/interp/setvart.boot @@ -1131,7 +1131,6 @@ $setOptions := '( -- algebra display output in algebraic form On:CONSOLE -- asgard show output in asgard form off -- characters choose special output character set plain --- script display output in SCRIPT formula format Off:CONSOLE -- fortran create output in FORTRAN format Off:CONSOLE -- fraction how fractions are formatted vertical -- length line length of output displays 77 @@ -1389,55 +1388,6 @@ $setOptions := '( "console")) NIL) --- ---------------------- The script Option ---------------------- --- --- Description: display output in SCRIPT formula format --- --- )set output script is used to tell AXIOM to turn IBM Script --- formula-style output printing on and off, and where to place --- the output. By default, the destination for the output is the --- screen but printing is turned off. --- --- Syntax: )set output script <arg> --- where arg can be one of --- on turn IBM Script formula printing on --- off turn IBM Script formula printing off --- (default state) --- console send IBM Script formula output to screen --- (default state) --- fp<.fe> send IBM Script formula output to file with file --- prefix fp and file extension .fe. If not given, --- .fe defaults to .sform. --- --- If you wish to send the output to a file, you must issue --- this command twice: once with on and once with the file --- name. For example, to send IBM Script formula output to --- the file polymer.sform, issue the two commands --- --- )set output script on --- )set output script polymer --- --- The output is placed in the directory from which you --- invoked AXIOM or the one you set with the )cd system command. --- The current setting is: Off:CONSOLE - (script - "display output in SCRIPT formula format" - interpreter - FUNCTION - setOutputFormula - (("display output in SCRIPT format" - LITERALS - $formulaFormat - (off on) - off) - (break $formulaFormat) - ("where script output goes (enter {\em console} or a a pathname)" - FILENAME - $formulaOutputFile - chkOutputFileName - "console")) - NIL) - -- --------------------- The scripts Option ---------------------- -- -- Description: show subscripts,... linearly diff --git a/src/interp/spad.lisp b/src/interp/spad.lisp index 02c9c87f..3811bdc4 100644 --- a/src/interp/spad.lisp +++ b/src/interp/spad.lisp @@ -50,7 +50,6 @@ (defvar |$functorForm| nil "checked in addModemap0") (defvar |$Rep| '|$Rep| "should be bound to gensym? checked in coerce") (defvar |$definition| nil "checked in DomainSubstitutionFunction") -(defvar |$formulaFormat| nil "if true produce script formula output") (defvar |$texFormat| nil "if true produce tex output") (defvar |$fortranFormat| nil "if true produce fortran output") (defvar |$algebraFormat| t "produce 2-d algebra output") diff --git a/src/interp/sys-globals.boot b/src/interp/sys-globals.boot index c2e13a16..c46ff38b 100644 --- a/src/interp/sys-globals.boot +++ b/src/interp/sys-globals.boot @@ -443,9 +443,6 @@ $texOutputStream := MAKE_-SYNONYM_-STREAM "*STANDARD-OUTPUT*" $fortranOutputStream := MAKE_-SYNONYM_-STREAM "*STANDARD-OUTPUT*" -$formulaOutputStream := - MAKE_-SYNONYM_-STREAM "*STANDARD-OUTPUT*" - conOutStream := MAKE_-SYNONYM_-STREAM "*STANDARD-OUTPUT*" |