ObjectAsMethods, MethodWrappers, and #perform:

Romain Robbes rrobbes at info.unicaen.fr
Tue Apr 20 09:02:59 UTC 2004


Hi Stef,

> just a remark. I would pay attention not to use too much reflective 
> stuff for the registration mechanism if this is for that that you want 
> to use MW. Registry should be explicit because they represent 
> architectural elements of a system and they should be crystal clear so 
> that people use them without magic. At least this is my perception of 
> that. I like the registration mechanim of the file list but I 
> influenced it a lot :)

Well I wasn't clear enough, but this for doing (yet) another registry, 
which would
store type information for class, methods ...

This is not used for services (it might use services to interface it in 
browsers
though ;-))


One use of this TypeRegistry is to run code using MethodWrappers and 
TypeSpy proxies
to fill up the registry based on run-time information.

It could also be manually filled is the programmer is unlazy enough to 
do it, or
maybe be type inferencers too.

Then it could be used to know the types of methods (receiver, 
arguments, return) and
classes (instVars, classVars (I stole some whisker code for that,
but that's not a problem since it was already stolen ;-))), so that the 
programmer can
analyse code quicker, and I'm also planning to use this type 
information for the next
version of my completion enhancements package.


Concerning reflective stuff in services, I have a bit of it I'm going 
to remove as
Avi rightfully pointed out.

	Romain




More information about the Squeak-dev mailing list