Java's modules rock? (was Re: election details *PLEASE READ*)

stephane ducasse stephane.ducasse at free.fr
Sat Mar 10 15:07:15 UTC 2007


On 6 mars 07, at 07:07, Andreas Raab wrote:

> Yes, I have. And if not for the need of having a very fast type  
> test (Object>>isFoo) I have rarely a need for them (and try to  
> avoid them as much as possible). Yes, there are situations in which  
> modifications to class Object can be useful, however, most of the  
> time there is no need for them and in the long term you are  
> typically better off without them than with them (partially because  
> you write your code more defensively).

Hi andreas

I agree that extending Object is not always the right solution.  
Especially with isSomething...
But they are cases where been able to add method is important.  
Especially since subclassing does not work
since the clients of the class you would like to extend will not see  
the added methods.

I have the impression that either only been able to add (and not  
overrides) I think that override are really evil.
could be a solution or something in the vein of selectorNamespace  
since you control the scope of your changes and you
do not impact existing code.

Now I would really like to see a concrete problem you have because I  
still would like to work on a good module
system. I'm not satisfied with classboxes even if we learned a lot  
designing it.

Stef



More information about the Squeak-dev mailing list