[Modules] Upper case message names for accessing modules

Doug Way dway at riskmetrics.com
Thu Feb 21 05:22:06 UTC 2002


Frank Sergeant wrote:
> 
> ducasse <ducasse at iam.unibe.ch> wrote:
> 
> > For ellipse := (Module path: #(Squeak Morphic Core Basic)
> >                      class: #EllipseMorph) new
> >
> > this could be better
> > as
> >     ellipse := (Module class: #EllipseMorph inPath: #(Squeak Morphic Core
> > Basic) new
> >     because we are interested in the class
> >
> > Or we can have something new to refer to class in namespace
> 
> Are you and/or the other module people saying that with a modularized
> Squeak system, everytime we wish to refer to a class that is in a
> module, we would need to use something like one of the above examples?
> I hope I have misunderstood!  I think that would be horrible.

Well, I mostly agree, but explicit module path naming wouldn't necessarily have to be used most of the time, which is what my (long-winded) "Namespaces..." post was about yesterday.  You could import names from other modules by default, or something similar, and then you would use the usual "ellipse := EllipseMorph new".  In the hopefully unusual case of an actual name clash, you would need to use something like one of the above examples, though.

(Or not exactly like the above, the other alternative was "ellipse := Squeak Morphic Core Basic EllipseMorph new".)

- Doug Way
  dway at riskmetrics.com



More information about the Squeak-dev mailing list