[Modules] Name space semantics was: Re: Some of my thoughts

Stephen Pair spair at advantive.com
Thu Aug 16 23:59:00 UTC 2001


> Having raised all of these questions, I'm not sure of the ultimate 
> virtue of the feature.  Is it good programming style to use, hence to 
> support, a module-specific use of a "little cap" squeak entity, 
> particularly a non-object?

It's already done today...look at just about any change set floating
about.

> Perhaps the better notion to use a subclass instead?

Perhaps a good exercise would be to take all of the goodies on the
Swiki, and attempt to refactor them such that they only use subclasses
(no loose methods).  But then, try to understand what you've produced,
and try to get them all to work together in the same image.  Does it
really make sense to have:

OrderedCollection
  MyOrderedCollection
    HansOrderedCollection
  JohnsOrderedCollection
    MyOrderedCollectionWithJohnAndHansStuffToo

Or, is it better to simply import John and Hans packages that modify
OrderedCollection and add my stuff?

> Which is the better programming style?   I am fearful we can 
> end up with 
> highly unmaintainable coding scenarios -- precisely the problem that 
> Modularity was supposed to avoid.
> 
> Now, I was never inculcated with Envy, so please don't flame me.  On 
> this question, count me a newbie.  But, I'd sure like some 
> introduction 
> to how this all would work from a user's perspective, and why 
> it would 
> be a "good thing." (R)

Imagine working in Squeak just as you do today, only with no fear...and
knowing that anything you change can be zapped into another image and
run flawlessly, no matter what else is (or isn't) loaded into that other
image.  That's the way it should be.

- Stephen





More information about the Squeak-dev mailing list