From andrew.pennebaker at gmail.com Wed Mar 2 07:13:12 2011 From: andrew.pennebaker at gmail.com (Andrew Pennebaker) Date: Wed, 2 Mar 2011 02:13:12 -0500 Subject: [cl-who-devel] Evaluating forms inside of with-html-output-to-string Message-ID: According to the documentation, with-html-output-to-string can evaluate Lisp forms. In my experience, this is not the case. (cl-who:with-html-output-to-string (*standard-output* nil :prologue nil :indent t) (:p (concatenate 'string "abc" "def"))) Should return "

abcdef

" but it actually returns "

" Specs: - Lispbox CCL 1.6 - Mac OS X 10.6.6 and Ubuntu 10.10 Maverick Cheers, Andrew Pennebaker -------------- next part -------------- An HTML attachment was scrubbed... URL: From osei.poku at gmail.com Wed Mar 2 07:23:46 2011 From: osei.poku at gmail.com (Osei Poku) Date: Wed, 2 Mar 2011 02:23:46 -0500 Subject: [cl-who-devel] Evaluating forms inside of with-html-output-to-string In-Reply-To: References: Message-ID: <814BA974-BB5D-4E8A-8E08-EF4DB605FB49@gmail.com> Try: (cl-who:with-html-output-to-string (*standard-output* nil :prologue nil :indent t) (:p (str (concatenate 'string "abc" "def")))) i.e., enclose the lisp form generating the string with (str ) Osei On Mar 2, 2011, at 2:13 AM, Andrew Pennebaker wrote: > According to the documentation, with-html-output-to-string can evaluate Lisp forms. In my experience, this is not the case. > > (cl-who:with-html-output-to-string (*standard-output* nil :prologue nil :indent t) > (:p (concatenate 'string "abc" "def"))) > > Should return > > "

> abcdef >

" > > but it actually returns > > "

>

" > > Specs: > ? Lispbox CCL 1.6 > ? Mac OS X 10.6.6 and Ubuntu 10.10 Maverick > Cheers, > Andrew Pennebaker > _______________________________________________ > cl-who-devel site list > cl-who-devel at common-lisp.net > http://common-lisp.net/mailman/listinfo/cl-who-devel From andrew.pennebaker at gmail.com Wed Mar 2 22:56:51 2011 From: andrew.pennebaker at gmail.com (Andrew Pennebaker) Date: Wed, 2 Mar 2011 17:56:51 -0500 Subject: [cl-who-devel] Evaluating forms inside of with-html-output-to-string In-Reply-To: <814BA974-BB5D-4E8A-8E08-EF4DB605FB49@gmail.com> References: <814BA974-BB5D-4E8A-8E08-EF4DB605FB49@gmail.com> Message-ID: Thanks for suggesting (str). The correct code (without importing the cl-who package): (cl-who:with-html-output-to-string (*standard-output* nil :prologue nil :indent t) (:p (cl-who:str (concatenate 'string "abc" "def")))) The current docs don't say anything about (format nil) not working inside of with-html-output-to-string; they just say that (str) has no binding. A simple notice would aid new Lispers, myself included. Cheers, Andrew Pennebaker www.yellosoft.us On Wed, Mar 2, 2011 at 2:23 AM, Osei Poku wrote: > Try: > > (cl-who:with-html-output-to-string (*standard-output* nil :prologue nil > :indent t) > (:p (str (concatenate 'string "abc" "def")))) > > i.e., enclose the lisp form generating the string with (str ) > > Osei > > On Mar 2, 2011, at 2:13 AM, Andrew Pennebaker wrote: > > > According to the documentation, with-html-output-to-string can evaluate > Lisp forms. In my experience, this is not the case. > > > > (cl-who:with-html-output-to-string (*standard-output* nil :prologue nil > :indent t) > > (:p (concatenate 'string "abc" "def"))) > > > > Should return > > > > "

> > abcdef > >

" > > > > but it actually returns > > > > "

> >

" > > > > Specs: > > ? Lispbox CCL 1.6 > > ? Mac OS X 10.6.6 and Ubuntu 10.10 Maverick > > Cheers, > > Andrew Pennebaker > > _______________________________________________ > > cl-who-devel site list > > cl-who-devel at common-lisp.net > > http://common-lisp.net/mailman/listinfo/cl-who-devel > > > _______________________________________________ > cl-who-devel site list > cl-who-devel at common-lisp.net > http://common-lisp.net/mailman/listinfo/cl-who-devel > -------------- next part -------------- An HTML attachment was scrubbed... URL: From edi at weitz.de Thu Mar 3 07:12:45 2011 From: edi at weitz.de (Edi Weitz) Date: Thu, 3 Mar 2011 08:12:45 +0100 Subject: [cl-who-devel] Evaluating forms inside of with-html-output-to-string In-Reply-To: References: <814BA974-BB5D-4E8A-8E08-EF4DB605FB49@gmail.com> Message-ID: On Wed, Mar 2, 2011 at 11:56 PM, Andrew Pennebaker wrote: > The?current docs?don't say anything about (format nil) not working inside of > with-html-output-to-string; they just say that (str) has no binding. The section "Syntax and Semantics" explains this in detail. I guess you just didn't read that...