[closer-devel] ContextL 0.40.

Pascal Costanza pc at p-cos.net
Sat Apr 21 21:35:19 UTC 2007


Hi everyone,

I have just released ContextL 0.40. The idea is that this version is  
feature-complete with regard to the feature set of the upcoming 1.0  
release. So the goal is to test this version now, and in the meantime  
I hope I will find enough time to write up some more decent  
documentation of ContextL before version 1.0 is eventually released.

IMPORTANT: There are some changes in the API of ContextL 0.40  
compared to previous versions. If you rely on the old version and  
cannot afford to switch to 0.40 yet for some reason, I have also  
provided a new version 0.32 which has the same API as before, but  
just fixes an important internal bug I have discovered recently. If  
for some reason you can indeed not switch to 0.40, please let me know  
and I'll see what I can do to fix potential issues.

For those who are willing to switch, here are the changes that will  
probably affect your code:

   + The functions activate-layer and activate-layer-using-class have  
been renamed to adjoin-layer and adjoin-layer-using-class, and  
deactivate-layer and deactivate-layer-using-class have been renamed  
to remove-layer and remove-layer-using-class. The new names reflect  
better what these functions actually do. However, the semantics  
haven't changed.

   + Removed the functions funcall-with-layers and apply-with-layers.  
Use the functions funcall-with-layer-context and apply-with-layer- 
context instead. (That API was ugly, and I guess it was never used.)

   + The deflayer macro doesn't take a :layer-class option anymore,  
but instead a :metaclass option. (I have tried to abstract from the  
internal representation as CLOS classes, but that turns out to be  
useless for the time being.) There is no change in semantics here,  
you just have to switch from :layer-class to :metaclass in a deflayer  
form, that's all.


And now to some of the new features in this release:

   + Added the functions funcall-with-layer-context and apply-with- 
layer-context, as hopefully better replacements for funcall-with- 
layers and apply-with-layers.

   + Added the function current-layer-context. This captures the set  
of currently active layers, which can later be reinstalled with  
funcall-with-layer-context and apply-with-layer-context. (This should  
be handy in conjunction with continuations, as for example in  
continuation-based web frameworks.)

   + Added the readers layered-function-definer, layered-function- 
argument-precedence-order, layered-function-lambda-list for layered- 
function objects.

   + Added the readers layered-method-lambda-list, layered-method- 
specializers, layered-method-layer for layered-method objects.

   + Added the readers slot-definition-layered-readers and slot- 
definition-layered-writers for layered slot definition metaobjects.

   + You can now specify an :in-layer option in slot specifiers. This  
means that a slot within a define-layered-class form can be declared  
to be in a different layer than the respective class itself. This  
should allow, for example, grouping of slots of different layers in  
the same define-layered-class form.

   + Layers and layered functions can now also have uninterned  
symbols as names. This enables a form of anonymous layers and  
anonymous layered functions when gensym is used to create names for  
them. It's then probably also better to pass these symbols around  
instead of the first-class layers or functions themselves.

   + Added the function ensure-layer for programmatically creating  
layers.


Finally some internal changes, which are not necessarily visible to  
application programmers:

   + Some of the :in-layer keyword parameters to internal functions  
have previously taken lists of layers for technical reasons. This is  
not the case anymore. This doesn't affect those who have used the  
define-layered-class, but if you have used plain defclass forms with  
the respective :metaclass options in the past, you may have to change  
the corresponding :in-layer class options.

   + Changed the internal handling of the :defining-metaclass option  
for partial classes. In the previous versions, that option actually  
didn't get recorded properly. Fortunately, that didn't affect the  
correctness of the behavioral semantics. (phew ;)

   + Layered direct slot definition metaobjects don't take :layered- 
reader, :layered-writer and :layered-accessor initargs anymore, but  
rather :layered-readers and :layered-writers, which is closer to how  
the CLOS MOP works as well.

   + Added methods for print-object for the major classes and  
metaclasses, such that, for example, debug output now prints more  
nicely.


So this all effectively means that I have kept my announcements from  
beginning of January of this year with a delay of only two months.  
(Hey, that's better than both Microsoft and Apple. ;)

Please feel free to ask any questions, either in the closer-devel  
mailing list (the preferred forum), or in private email.


Cheers,
Pascal

-- 
Pascal Costanza, mailto:pc at p-cos.net, http://p-cos.net
Vrije Universiteit Brussel, Programming Technology Lab
Pleinlaan 2, B-1050 Brussel, Belgium







More information about the closer-devel mailing list