string too long from write-char
[email protected] (Don Cohen)
| Newsgroups | gmane.lisp.clisp.general |
|---|---|
| Message-ID | <[email protected]> |
This comes from ...
$ clisp --version
GNU CLISP 2.49 (2010-07-07) (built on x86-07.phx2.fedoraproject.org [10.5.125.17])
Software: GNU C 4.6.3 20120306 (Red Hat 4.6.3-2)
gcc -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i686 -mtune=atom -fasynchronous-unwind-tables -I/usr/include/readline5 -I/usr/include/libsvm -Wa,--noexecstack -L/usr/lib/readline5 -W -Wswitch -Wcomment -Wpointer-arith -Wimplicit -Wreturn-type -Wmissing-declarations -Wno-sign-compare -Wno-format-nonliteral -O2 -fexpensive-optimizations -falign-functions=4 -DENABLE_UNICODE -DDYNAMIC_FFI -DDYNAMIC_MODULES -I. -L/usr/lib/readline5 -Wl,-z,noexecstack /builddir/build/BUILD/clisp-2.49/readline/lib/libreadline.so -L/builddir/build/BUILD/clisp-2.49/readline/lib -lncurses -ldl /usr/lib/libavcall.a /usr/lib/libcallback.a -L/usr/lib -lsigsegv libgnu_cl.a
SAFETY=0 HEAPCODES LINUX_NOEXEC_HEAPCODES GENERATIONAL_GC SPVW_BLOCKS SPVW_MIXED TRIVIALMAP_MEMORY
libsigsegv 2.10
libreadline 5.2
Features:
(READLINE REGEXP SYSCALLS I18N LOOP COMPILER CLOS MOP CLISP ANSI-CL COMMON-LISP
LISP=CL INTERPRETER SOCKETS GENERIC-STREAMS LOGICAL-PATHNAMES SCREEN FFI
GETTEXT UNICODE BASE-CHAR=CHARACTER PC386 UNIX)
C Modules: (clisp i18n syscalls regexp readline)
Installation directory: /usr/lib/clisp-2.49/
User language: ENGLISH
Machine: I686 (I686) localhost.localdomain [127.0.0.1]
(gdb) bt
#0 error_stringsize (size=5242880) at ../src/error.d:1224
#1 0x080e0912 in ssstring_extend_low (ssstring=<optimized out>, size=5242880)
at ../src/array.d:4063
#2 0x080e7b7b in ssstring_push_extend (ssstring=0x2041653e, ch=27)
at ../src/array.d:4099
#3 0x080ae240 in wr_ch_terminal3 (stream_=0xb7c265b4, ch=0xc0000370)
at ../src/stream.d:9857
#4 0x080bc1cf in write_char (stream_=0xb7c265b4, ch=0xc0000370)
at ../src/stream.d:895
#5 0x080df674 in C_write_char () at ../src/io.d:10430
#6 0x0808ff35 in eval_subr (fun=0x822b796) at ../src/eval.d:3592
#7 0x0808e79e in eval1 (form=0x6801b5aa) at ../src/eval.d:3084
#8 0x0808fbd1 in eval (form=0x6801b5aa) at ../src/eval.d:2966
#9 0x0809364f in C_progn () at ../src/control.d:296
#10 0x0808ead4 in eval_fsubr (args=<optimized out>, fun=0x202aaeae)
at ../src/eval.d:3263
#11 eval1 (form=<optimized out>) at ../src/eval.d:3101
#12 0x0808fbd1 in eval (form=0x6801b5b2) at ../src/eval.d:2966
#13 0x0809127f in funcall_iclosure (closure=<optimized out>,
args_pointer=<optimized out>, argcount=<optimized out>)
at ../src/eval.d:2744
#14 0x0808ecf3 in eval_closure (closure=0x204182a6) at ../src/eval.d:3935
#15 eval1 (form=<optimized out>) at ../src/eval.d:3091
#16 0x0808fbd1 in eval (form=0x680192ca) at ../src/eval.d:2966
#17 0x0809127f in funcall_iclosure (closure=<optimized out>,
args_pointer=<optimized out>, argcount=<optimized out>)
at ../src/eval.d:2744
Before I go much further trying to understand wr_ch_terminal3
maybe someone could tell me what's going on and what to do about it.
Is this a matter of clisp thinking that the terminal has a very long
line?
SYSTEM::*PRIN-LINELENGTH* seems to be 80.
Also it's curious that if I simply type redo then I'm good for
another 5M characters (as described in an earlier message).
I also think the error does not occur if I do some output to another
stream occasionally. 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?
------------------------------------------------------------------------------
_______________________________________________
clisp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/clisp-list