[cl-pdf-devel] cl-pdf examples not working in cmucl 19a
David J Cooper Jr
david.cooper at genworks.com
Wed Aug 18 20:19:59 UTC 2004
Hello cl-pdfers,
I have seen the kind of error Chisheng refers to below in Allegro as
well, and I believe it is due to the
with-standard-io-syntax
in pdf.lisp which binds *print-readably* to T.
I have added a
....
(let (*print-readably*)
....
within the with-standard-io-syntax in order to suppress the
*print-readably* being T, and I question whether we really need
*print-readably* set to T by default throughout cl-pdf and
cl-typesetting (it was added in release 2.1 of cl-pdf with
explanation:
Added a few with-standard-io-syntax so that the pdf are generated
correctly when people change the printer settings.
I'm not sure what this means with respect to *print-readably* being T
or NIL however. With *print-readably* T it makes, for example,
printing debug output difficult since object instances generally
cannot be printed without doing something extra (a print-object
method?)
Thanks,
-dave
Chisheng Huang writes:
> Hi,
>
> I downloaded cl-pdf-current.tgz yesterday and managed to get
> it compiled and loaded on a Red Hat 7.3 box with
> 1. CMUCL 19a (x86 Linux) plus contrib/zlib-cmucl.lisp
> 2. LispWorks personal edition 4.3.6. plus contrib/zlib-lw.lisp
>
> All examples in examples/examples.lisp work in Lispworks but none
> of them work in CMUCL. The backtrace of running EXAMPLE1 is attached
> at the end of this email. I'll be grateful if someone can show me how
> to get around this problem.
>
> I'm sorry if this is not the right place to ask this type of questions.
>
> Best wishes,
>
> -cph
>
> -------------------- backtrace --------------------
>
> #<Wrapper #<STANDARD-CLASS PDF::NAMED-REFERENCE {580778ED}> {5806B115}> cannot be printed readably.
> [Condition of type PRINT-NOT-READABLE]
>
> Restarts:
> 0: [ABORT] Abort handling SLIME request.
> 1: Return to Top-Level.
>
> Debug (type H for help)
>
> (LISP::%PRINT-UNREADABLE-OBJECT #<Wrapper #<STANDARD-CLASS PDF::NAMED-REFERENCE {580778ED}> {5806B115}> #<String-Output Stream> NIL T ...)
> Source:
> ; File: target:code/print.lisp
> (ERROR (QUOTE PRINT-NOT-READABLE) :OBJECT OBJECT)
> 0] back
>
> 0: (LISP::%PRINT-UNREADABLE-OBJECT #<Wrapper #<STANDARD-CLASS PDF::NAMED-REFERENCE {580778ED}> {5806B115}> #<String-Output Stream> NIL T ...)
> 1: (LISP::OUTPUT-LIST (SETF (PCL::STD-INSTANCE-WRAPPER PCL::.INSTANCE.) #<Wrapper #<STANDARD-CLASS PDF::NAMED-REFERENCE {580778ED}> {5806B115}>) #<String-Output Stream>)
> 2: (LISP::OUTPUT-LIST (LET (# #) (SETF # #<Wrapper #<STANDARD-CLASS PDF::NAMED-REFERENCE {580778ED}> {5806B115}>) (SETF # PCL::.SLOTS.) (LET NIL #) ...) #<String-Output Stream>)
> 3: (LISP::OUTPUT-LIST (KERNEL:INSTANCE-LAMBDA (PCL::|.P0.|) (LET # # # # ...)) #<String-Output Stream>)
> 4: (PRIN1 (KERNEL:INSTANCE-LAMBDA (PCL::|.P0.|) (LET # # # # ...)) #<String-Output Stream>)
> 5: (FORMAT::S-FORMAT-DIRECTIVE-INTERPRETER #<String-Output Stream> #<~S> (#<~^> " ") #<unused-arg> ...)
> 6: (FORMAT::INTERPRET-DIRECTIVE-LIST #<String-Output Stream> (#<~S> #<~^> " ") (FUNCTION (KERNEL:INSTANCE-LAMBDA # #)) ((KERNEL:INSTANCE-LAMBDA # #)))
> 7: ((LABELS FORMAT::DO-LOOP FORMAT::{-FORMAT-DIRECTIVE-INTERPRETER) (FUNCTION (KERNEL:INSTANCE-LAMBDA # #)) ((KERNEL:INSTANCE-LAMBDA # #)))
> 8: (FORMAT::{-FORMAT-DIRECTIVE-INTERPRETER #<String-Output Stream> #<~{> (#<~S> #<~^> " " #<~}> #<~^> ...) ((FUNCTION #)) ...)
> 9: (FORMAT::INTERPRET-DIRECTIVE-LIST #<String-Output Stream> (#<~{> #<~S> #<~^> " " #<~}> ...) ((FUNCTION #)) ((FUNCTION #)))
> 10: ((LABELS FORMAT::DO-LOOP FORMAT::{-FORMAT-DIRECTIVE-INTERPRETER) ((FUNCTION #)) ((FUNCTION #)))
> 11: (FORMAT::{-FORMAT-DIRECTIVE-INTERPRETER #<String-Output Stream> #<~{> (#<~{> #<~S> #<~^> " " #<~}> ...) ((#)) ...)
> 12: (FORMAT::INTERPRET-DIRECTIVE-LIST #<String-Output Stream> (#<~{> #<~{> #<~S> #<~^> " " ...) ((#)) ((#)))
> 13: (FORMAT::%FORMAT #<String-Output Stream> "~{~{~S~^ ~}~^ => ~}" ((#)) ((#)))
> 14: (FORMAT NIL "~{~{~S~^ ~}~^ => ~}" ((FUNCTION #)))
> 15: (C::FIND-COMPONENT-NAME #<C:COMPONENT 58F62F5D NAME= "<unknown>">)
> 16: (C::FIND-TOP-LEVEL-COMPONENTS (#<C:COMPONENT 58F62F5D NAME= "<unknown>"> #<C:COMPONENT 58F6353D NAME= "<unknown>">))
> 17: ((FLET #:G0 COMPILE))
> 18: (COMPILE (MAKE-INSTANCE PDF::NAMED-REFERENCE :NAME PCL::|.P0.|) (KERNEL:INSTANCE-LAMBDA (PCL::|.P0.|) (LET # # # # ...)))
> 19: (COMPILE 2 (MAKE-INSTANCE PDF::NAMED-REFERENCE :NAME PCL::|.P0.|) (KERNEL:INSTANCE-LAMBDA (PCL::|.P0.|) (LET # # # # ...)))[:EXTERNAL]
> 20: (PCL::COMPILE-LAMBDA (KERNEL:INSTANCE-LAMBDA (PCL::|.P0.|) (LET # # # # ...)) :NAME (MAKE-INSTANCE PDF::NAMED-REFERENCE :NAME PCL::|.P0.|) :INLINE ...)
> 21: ((LABELS PCL::INSTALL PCL::INSTALL-OPTIMIZED-CONSTRUCTOR) T)
> 22: ("DEFUN INSTALL-INITIAL-CONSTRUCTOR" "R101")
> 23: (PDF:GET-NAMED-REFERENCE "R101")
> 24: (PDF::REGISTER-NAMED-REFERENCE #(#<PDF::PAGE {58E9C755}> "/Fit") "R101")
> 25: (PDF:REGISTER-PAGE-REFERENCE "R101")
> 26: ("DEFUN EXAMPLE1")
> 27: (LISP::%WITH-STANDARD-IO-SYNTAX #<Function "DEFUN EXAMPLE1" {58B290B1}>)
> 28: (EXAMPLE1 #p"/tmp/ex1.pdf")
>
>
> _______________________________________________
> cl-pdf-devel site list
> cl-pdf-devel at common-lisp.net
> http://common-lisp.net/mailman/listinfo/cl-pdf-devel
>
>
More information about the cl-pdf-devel
mailing list