You can generate this problem more easily from the REPL as sollows (disassemble '(lambda () (setf (fill-pointer xxx) 0))
However this is OK (disassemble '(lambda (n) (setf (fill-pointer xxx) n))) But this is not... it looks like an optimization that happens when it knows the parameter is a fixnum. (disassemble '(lambda (n) (declare (fixnum n)) (setf (fill-pointer xxx) n))) Regards, Tim Josling On Sun, 2007-12-16 at 06:54 +1100, Tim Josling wrote: > System: > uname -a > Linux tim-gcc 2.6.20-15-generic #2 SMP Sun Apr 15 06:17:24 UTC 2007 > x86_64 GNU/Linux > > GCL: > GCL (GNU Common Lisp) 2.6.7 CLtL1 Nov 10 2006 14:25:02 > > Run log of error: > > make cobol-tests > gcl \ > -eval "(compile-file > \"/home2/gcb/gcb/gcc/gcc/gcb/gcbc-compiler-lexer.lisp\")" > GCL (GNU Common Lisp) 2.6.7 CLtL1 Nov 10 2006 14:25:02 > Source License: LGPL(gcl,gmp), GPL(unexec,bfd,xgcl) > Binary License: GPL due to GPL'ed components: (XGCL READLINE BFD > UNEXEC) > Modifications of this banner must retain notice of a compatible license > Dedicated to the memory of W. Schelter > > Use (help) to get some basic information on how to use GCL. > Temporary directory for compiler files set to /tmp/ > Compiling /home2/gcb/gcb/gcc/gcc/gcb/gcbc-compiler-lexer.lisp. > End of Pass 1. > End of Pass 2. > /home2/gcb/gcb/gcc/gcc/gcb/gcbc-compiler-lexer.c: In function 'L1': > /home2/gcb/gcb/gcc/gcc/gcb/gcbc-compiler-lexer.c:5158: error: invalid > lvalue in assignment > > Error: (SYSTEM "gcc -c -Wall -DVOL=volatile -fsigned-char -pipe > -I/usr/lib/gcl-2.6.7/unixport/../h -O3 -fomit-frame-pointer -c > \"/home2/gcb/gcb/gcc/gcc/gcb/gcbc-compiler-lexer.c\" -o > \"/home2/gcb/gcb/gcc/gcc/gcb/gcbc-compiler-lexer.o\" -w") returned a > non-zero value 0. > Fast links are on: do (si::use-fast-links nil) for debugging > Error signalled by UNLESS. > Broken at CERROR. Type :H for Help. > >> > > Input program: > ;;; -*- lisp -*- > > (defvar *current-token-chars* nil) > > (defun init-token-chars () > (setf (fill-pointer *current-token-chars*) 0)) > > Output C code (excerpt): > > #include "gcbc-compiler-lexer.h" > void init_code(){do_init((void *)VV);} > /* function definition for INIT-TOKEN-CHARS */ > > static void L1() > {register object *base=vs_base; > register object *sup=base+VM1; VC1 > vs_check; > vs_top=sup; > goto TTL; > TTL:; > base[0]= > CMPmake_fixnum((long)(((((object)VV[0])->s.s_dbind))->st.st_fillp)=((long)0)); > > vs_top=(vs_base=base+0)+1; > return; > } > > This is the bad line: > CMPmake_fixnum((long)(((((object)VV[0])->s.s_dbind))->st.st_fillp)=((long)0)); > > > Regards, > Tim Josling _______________________________________________ Gcl-devel mailing list Gcl-devel@gnu.org http://lists.gnu.org/mailman/listinfo/gcl-devel