Hi,
currently I am experiencing a quite strange behaviour with slime and (I think) clsql:
I had two lisp-files with def-view-class'es for two different databases, plus some interface functions. Everything worked fine. However, I had to merge the databases into different tables in one database and merrged the two lisp-files, too. Since then I two strange things happen:
1. First time I load the whole project (,l at the REPL) everything is fine (except for repeated compilations of some files in clsql; I posted that to clsql-help-list). But when I try to do that again, the files get compiled and then lisp goes into an endless loop, growing in memory as long as I say sayoonara to the REPL.
2. When trying to go to a function defined in that file (M-.) I end up at the previous defun in that file.
I use CVSHEAD slime, CMU Common Lisp CVS 19b 19b-release-20050628-3 + minimal debian patches (19B), XEmacs 21.4 (patch 17) "Jumbo Shrimp" XEmacs Lucid.
Can anyone give my any pointers what may be wrong here?
Regards and thanks, Stefan
Hi,
I could enlight things a bit by getting a backtrace-printing function hooked to *after-gc-hooks*. I think the relevant parts of this are:
---------------------------------------------------------- 5: (LISP::MAYBE-GC NIL) 6: ("call_into_lisp+#x8C [#x8054EDC] /usr/bin/lisp") 7: ("funcall0+#x27 [#x8054C6A] /usr/bin/lisp") 8: ("alloc+#xDE [#x805E253] /usr/bin/lisp") 9: ("alloc_overflow_edx+#xE [#x80550CA] /usr/bin/lisp") 10: (LISP::READ-MAYBE-NOTHING #<Stream for file "/home/ska/prj/lisp/broom/broom-db-interface.lisp"> #[) 11: (LISP::READ-LIST #<Stream for file "/home/ska/prj/lisp/broom/broom-db-interface.lisp"> #<unused-arg>) 12: (LISP::READ-MAYBE-NOTHING #<Stream for file "/home/ska/prj/lisp/broom/broom-db-interface.lisp"> #() 13: (LISP::READ-LIST #<Stream for file "/home/ska/prj/lisp/broom/broom-db-interface.lisp"> #<unused-arg>) 14: (LISP::READ-MAYBE-NOTHING #<Stream for file "/home/ska/prj/lisp/broom/broom-db-interface.lisp"> #() 15: (LISP::READ-LIST #<Stream for file "/home/ska/prj/lisp/broom/broom-db-interface.lisp"> #<unused-arg>) 16: (LISP::READ-PRESERVING-WHITESPACE-INTERNAL #<Stream for file "/home/ska/prj/lisp/broom/broom-db-interface.lisp"> T NIL T) ... 21: (SWANK-BACKEND::READ-SOURCE-FORM 13 #<Stream for file "/home/ska/prj/lisp/broom/broom-db-interface.lisp">) 22: (SWANK-BACKEND::SOURCE-PATH-STREAM-POSITION (13 4 1 1 3) #<Stream for file "/home/ska/prj/lisp/broom/broom-db-interface.lisp">) 23: (SWANK-BACKEND::SOURCE-PATH-FILE-POSITION (13 4 1 1 3)
#P"/home/ska/prj/lisp/broom/broom-db-interface.lisp") 24: (SWANK-BACKEND::LOCATE-COMPILER-NOTE #P"/home/ska/prj/lisp/broom/broom-db-interface.lisp" "; (SQL-= #<CLSQL-SYS:SQL-IDENT-ATTRIBUTE COMMWAYID> COMMWAY) " (13 4 1 1 3)) 25: (SWANK-BACKEND::COMPILER-NOTE-LOCATION #<Compiler-Error-Context>) 26: (SWANK-BACKEND::SIGNAL-COMPILER-CONDITION #<SIMPLE-WARNING {589F198D}> #<Compiler-Error-Context>) 27: (SIGNAL #<SIMPLE-WARNING {589F198D}>) 28: (C::COMPILER-WARNING-HANDLER #<SIMPLE-WARNING {589F198D}>) 29: (SIGNAL #<SIMPLE-WARNING {589F198D}>) 30: (WARN "Undefined ~(~A~) ~S~@[ ~A~]" :VARIABLE BROOM::COMMWAY NIL) ----------------------------------------------------------
I tmight be worth noting that that file uses the special sql-syntax of clsql:
#.(locally-enable-sql-reader-syntax) ;; ... #.(restore-sql-reader-syntax-state)
and that this is the file in which I always land one defun in front.
Does this help?
Regards, Stefan
On Fri, 4 Nov 2005 13:43:49 +0100 (MET), "Stefan Kamphausen" skampi@gmx.net wrote:
I tmight be worth noting that that file uses the special sql-syntax of clsql:
#.(locally-enable-sql-reader-syntax) ;; ... #.(restore-sql-reader-syntax-state)
and that this is the file in which I always land one defun in front.
Replace that with
(eval-when (:compile-toplevel :load-toplevel :execute) (setq *readtable* (copy-readtable)) (clsql:locally-enable-sql-reader-syntax))
and then you don't need to switch it off at the end of the file. Search the mailing list for a similar bug report of mine a couple of months ago.
Cheers, Edi.
Hi Edi,
#.(locally-enable-sql-reader-syntax) ;; ... #.(restore-sql-reader-syntax-state)
and that this is the file in which I always land one defun in front.
Replace that with
(eval-when (:compile-toplevel :load-toplevel :execute) (setq *readtable* (copy-readtable)) (clsql:locally-enable-sql-reader-syntax))
Works fine. Thank you!
and then you don't need to switch it off at the end of the file. Search the mailing list for a similar bug report of mine a couple of months ago.
Funny. Reading that thread I find that I have been about halfway through your experiences. The very minute your answer arrived I came to the conclusion that the #.(HACK) is really the origin of the error. It would have taken me several hours to arrive at eval-when, though. I was just starting to fiddle around with package names. So, again, thanks! :-)
Regards, Stefan