Re: string too long from write-char
"Pascal J. Bourguignon" <[email protected]>
| Newsgroups | gmane.lisp.clisp.general |
|---|---|
| Organization | Informatimago |
| Message-ID | <[email protected]> |
[email protected] (Don Cohen) writes: > The code: > (defun copy-utl2() > (loop for i below 160000 do > ;;(when (= 0 (mod i 10000))(print i iq::data)) > (write-char #\space data))) > When I do the print i without the stream argument the error goes away. > iq::data is a generic stream. > Maybe generic streams by default have very long lines? > Can this be controlled? WFM - Works for me: [pjb@kuiper :0.0 ~]$ clisp -norc i i i i i i i ooooo o ooooooo ooooo ooooo I I I I I I I 8 8 8 8 8 o 8 8 I \ `+' / I 8 8 8 8 8 8 \ `-+-' / 8 8 8 ooooo 8oooo `-__|__-' 8 8 8 8 8 | 8 o 8 8 o 8 8 ------+------ ooooo 8oooooo ooo8ooo ooooo 8 Welcome to GNU CLISP 2.49+ (2010-07-17) <http://clisp.org/> Copyright (c) Bruno Haible, Michael Stoll 1992, 1993 Copyright (c) Bruno Haible, Marcus Daniels 1994-1997 Copyright (c) Bruno Haible, Pierpaolo Bernardi, Sam Steingold 1998 Copyright (c) Bruno Haible, Sam Steingold 1999-2000 Copyright (c) Sam Steingold, Bruno Haible 2001-2010 Type :h and hit Enter for context help. [1]> (defun copy-utl2 (data) (loop for i below 160000 do (write-char #\space data))) COPY-UTL2 [2]> (with-open-file (data "/tmp/data" :if-does-not-exist :create :if-exists :supersede :direction :output) (copy-utl2 data)) NIL [3]> -- __Pascal Bourguignon__ http://www.informatimago.com/ “The factory of the future will have only two employees, a man and a dog. The man will be there to feed the dog. The dog will be there to keep the man from touching the equipment.” -- Carl Bass CEO Autodesk ------------------------------------------------------------------------------ _______________________________________________ clisp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/clisp-list