Stéphane Ducasse wrote: > I'm not sure that forbidding new: is a good idea. > In Smalltalk it is rare to forbid such methods. >
There are actually quite a few examples in existing code where #new and #new: are implemented as #shouldNotImplement or #error:. Classes that require a special way of creating their instances, such as CompiledMethod, often disallow new:. Singleton classes disallow new. Symbols seem to fit the pattern pretty well, and although it doesn't cause huge problems it seems like you shouldn't be able to create an invalid system state by sending public messages like #new:. Regards, -Martin _______________________________________________ Pharo-project mailing list [email protected] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
