[squeak-dev] Re: Future of Squeak, and outsider's view
Andreas Raab
andreas.raab at gmx.de
Tue Jun 30 18:37:42 UTC 2009
Eliot Miranda wrote:
> Arguably not. (BTW VW has had it from 98). The crucial difference is that
> in VW an extension can be in more than one package. In Squeak a selector
> can only be in a single Monticello extension category. That leads to
> the awful bug that when an MC package patches a base selector to extend
> it to fix a bug it ends up in the package and its membership of the
> package it was in previously being lost. I understand that with method
> history this situation can be detected but if you e.g. condense changes
> then that history is lost, and the base package selector becomes only an
> extension Ouch.
That's a bug in condenseChanges, not a conceptual problem. BTW, I really
fail to see how it would make any difference whatsoever if extension
methods are in multiple packages or not. In either case you are
*completely* screwed if you have multiple packages trying to extend the
same method. Seriously, has there ever been a situation where that
actually works? (my personal preference is actually that MC should blow
up straight into your face if you try to change a method that's in an
extension category already, but that's just me - I generally avoid
extensions like the plague)
> The VW "solution" is OK as far as it goes; a package is a set of class,
> selector pairs (more than this, but this is the essence). An MC package
> is defined by class and method categories. VW's parcels are
> intensional, MC packages are extensional.
I don't understand the distinction you are making between intensional
and extensional. Care to elaborate?
MC internally actually uses a set of class and selector pairs as well,
it just derives them via PackageInfo from categories. And it most
certainly can have methods in multiple packages. For example, if you add
a method in category '*Foo-Bar-Baz' it will be part of the packages
'Foo-Bar-Baz', 'Foo-Bar' and 'Foo' (if those exist).
The only thing that prevents you from having other combinations of
multiple package memberships is that there is no UI that allows you to
specify which combinations of packages a method should be part of. The
category hack is great because it works with existing tools, but
existing tools don't allow for methods in multiple categories. If you
fix that you get your multiple package membership in Monticello for
free. Alternatively provide a UI to specify which other packages the
method should be part of, and you're there, too.
Cheers,
- Andreas
More information about the Squeak-dev
mailing list
|