[Bese-devel] UCW-CORE cleanup/separation-of-concerns patch vol. 1
Hazen Babcock
hbabcock at mac.com
Fri Mar 30 02:31:06 UTC 2007
On Mar 29, 2007, at 7:04 PM, Attila Lendvai wrote:
>> Um, aren't "traditional" UCW applications basically composed of
>> defaction and defcomponent forms? I know that I use it a lot.
>
> the strongest counter argument against defaction is that it's a simple
> defmethod/cc, only with a different name. keeping track of when you
> are leaving the call/cc boundary is important and for newcomers its
> just a little harder with defmethod/cc hidden behind defaction.
>
> iow, in my view defaction in today's ucw code only introduces a new
> construct (to be learned, maintained, documented) without abstracting
> away much. and at the same time its name clashes with a completly
> different construct also called "action".
>
> the implicit self argument is also a little confusing for newcomers
> and questions always keep popping up about errors due to not being
> aware of this.
>
> i don't want to sound zealous about removing defaction, i don't really
> care because i already know what's behind it... i just wanted to make
> sure the con reasons are mentioned before i forget my newcomer days...
> :)
Well, it also prints out a message that can be useful for tracking
what sorts of things users are trying to do on your site. However I
also don't want to sound too zealous about keeping it. I typically
rolled it into another macro that put @body into a separate function
that was called by defaction so that I could get more feedback from
the compiler about errors I may have made.
There will be a few UCW tutorials that will need updating...
-Hazen
More information about the bese-devel
mailing list