[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Axiom-developer] lisp -> spad question
From: |
Arthur Ralfs |
Subject: |
[Axiom-developer] lisp -> spad question |
Date: |
Wed, 12 Sep 2007 19:52:01 -0700 |
User-agent: |
Thunderbird 1.5.0.12 (X11/20060911) |
Hello,
The following lisp seems to do what I want, i.e. capture stuff written to
*standard-output* in a string,
(1) -> )lisp (setq out (with-output-to-string (*standard-output*)
(write-line "hello universe")))
(1) ->
Value = "hello universe
"
(1) -> )lisp (write-line out)
hello universe
Value = "hello universe
"
However when I try to translate this to spad with the following function:
testCommand2():Void ==
SETQ(out$Lisp,WITH_-OUTPUT_-TO_-STRING(LIST(_*STANDARD_-OUTPUT_*$Lisp)$Lisp,
WriteLine("Hello Universe")$Lisp)$Lisp)$Lisp
I get this:
(1) -> testCommand2()
Loading /home/arthur/axiom/silver/silver-07-08-25/AXSERV.nrlib/code
for package AxiomServer
>> System error:
#<synonym stream to *TERMINAL-IO*> is not a string with a fill-pointer.
Can anybody tell me what's going on?
Thanks
Arthur Ralfs
- [Axiom-developer] lisp -> spad question,
Arthur Ralfs <=