aboutsummaryrefslogtreecommitdiff
path: root/src/interp
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2008-01-08 14:23:30 +0000
committerdos-reis <gdr@axiomatics.org>2008-01-08 14:23:30 +0000
commita90e0b91cdd543cc28abf425355c801279482ad6 (patch)
tree3f322cc2a533a443fe31463392dd0ff2ba10b0cb /src/interp
parent8d42d860e9f2fa6b71cfc1840134ad3b2a0a5dc9 (diff)
downloadopen-axiom-a90e0b91cdd543cc28abf425355c801279482ad6.tar.gz
* boot/Makefile.pamphlet (AXIOM_LOCAL_LISP): Use Lisp image with C
bindings. * interp/msgdb.boot (brightPrint0): Don't highlight if the standard output is not attached to a terminal. * interp/sys-driver.boot (stdStreamIsTerminal): New. * lib/cfuns-c.c (std_stream_is_terminal): New.
Diffstat (limited to 'src/interp')
-rw-r--r--src/interp/msgdb.boot6
-rw-r--r--src/interp/sys-driver.boot9
2 files changed, 13 insertions, 2 deletions
diff --git a/src/interp/msgdb.boot b/src/interp/msgdb.boot
index 3b72b074..bfd8e1ff 100644
--- a/src/interp/msgdb.boot
+++ b/src/interp/msgdb.boot
@@ -654,12 +654,14 @@ brightPrint0 x ==
x = '"%%" =>
sayString '"%"
x = '"%b" =>
- NULL IS_-CONSOLE CUROUTSTREAM => sayString '" "
+ NULL IS_-CONSOLE CUROUTSTREAM
+ or stdStreamIsTerminal(1) = 0 => sayString '" "
NULL $highlightAllowed => sayString '" "
sayString $highlightFontOn
k := blankIndicator x => BLANKS k
x = '"%d" =>
- NULL IS_-CONSOLE CUROUTSTREAM => sayString '" "
+ NULL IS_-CONSOLE CUROUTSTREAM
+ or stdStreamIsTerminal(1) = 0 => sayString '" "
NULL $highlightAllowed => sayString '" "
sayString $highlightFontOff
STRINGP x => sayString x
diff --git a/src/interp/sys-driver.boot b/src/interp/sys-driver.boot
index 2bd991fa..8cc54fad 100644
--- a/src/interp/sys-driver.boot
+++ b/src/interp/sys-driver.boot
@@ -64,4 +64,13 @@ systemAlgebraDirectory() ==
ensureTrailingSlash cdr dir
nil
+++ stdStreamIsTerminal:
+++ returns 1 if the standard stream is attached to a terminal;
+++ otherwise 0.
+)if %hasFeature KEYWORD::GCL
+import stdStreamIsTerminal for std__stream__is__terminal: INT -> INT
+)else
+stdStreamIsTerminal fd ==
+ 0
+)endif