"Leslie P. Polzer" <[email protected]> writes:
[...]
> You might consider adopting SBCL's DEFTRANSFORM framework for
> handling source-to-source transformations.

It sounds like a huge framework for adoption -- I didn't realise it was
able to do complex transforms like the CPS transform. Could you explain
a little more?

The patch for reducing the amount of stuff transformed tends to get it
massively wrong. I guess it's crying out for an even simpler
intermediate form than just removing the macros . . .

>> Would you be adverse to including macroexpand-dammit as a preprocessing
>> stage?  -- It cleans out all the macrolets and symbol-macrolets, making
>> the next stage much cleaner.http://paste.lisp.org/display/83349
>>
>> I've tested it on most current lisps.
>
> I'm in favor of this, but a patch should include at least basic
> automated tests for it.

Unfortunately I rather doubt that it would pass real testing as it
is. :-)
http://john.freml.in/static-blog/macroexpand-dammit/macroexpand-dammit.lisp

--- old-cl-cont/src/walker.lisp 2009-07-29 15:03:33.221534221 +0000
+++ new-cl-cont/src/walker.lisp 2009-07-29 15:03:33.261547270 +0000
@@ -8,7 +8,9 @@
 passing style."
   (let ((*ctx* (make-call/cc-context)))
     (declare (special *ctx*))
-    (expr-sequence->cps body '#'values env)))
+    (expr-sequence->cps 
+     (mapcar (lambda (f) (macroexpand-dammit:macroexpand-dammit f env)) body) 
+     '#'values env)))
 
 (defun expr->cps (expr k-expr env)
   "Transforms expression to CPS style."

causes the documentation tests to fail on SBCL beyond the two (related
to the order of macroexpansion) expected on ClozureCL. I will look into
this and the worrying warnings emitted.

Would anybody happen to know a good place to start with serious tests?
-- maybe http://www.cliki.net/GCL ANSI Test Suite

> I gather that usual implementations of MACROEXPAND-ALL do not remove
> (SYMBOL-)MACROLETs?

They expand the bodies but leave the macrolet definitions.

[...]


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"weblocks" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/weblocks?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to