mklein@aisunk.cs.uiuc.edu (09/27/89)
I would like to be able to pretty print an sexp into a string, as opposed to into a stream. How can I do this (on a TI Explorer)? Simply giving NIL as the stream to pprint does not work. Thanks for any suggestions, Mark
cerys@BBN.COM (Dan Cerys) (09/27/89)
Common Lisp supports the following: (with-output-to-string (stream) (pprint object stream))
ttf@VAX3.ITI.ORG ("Tihamer T. Toth-Fejel") (09/27/89)
I would like to be able to pretty print an sexp into a string, as opposed to into a stream. How can I do this (on a TI Explorer)? Simply giving NIL as the stream to pprint does not work. Thanks for any suggestions, Mark Please let me know when you get it done. I've wanted to know how to do the same thing. OOPS! Hold the presses! I just got an idea! (two minutes later) Yep, see pg. 5-8 of Lisp I/O Reference on write-to-string specifically: (write-to-string sexpr :pretty t) Does just what you want it to. internet: ttf@iti.org (Tihamer T. Toth-Fejel) Industrial Technologies Institute, Ann Arbor, Michigan 48106 (313) 769-4248 or 4345 home: (313) 622-4741 *----*----*----*----*----*----*----*----*----*----*----*----*----*