Squeak and Namespaces

Lex Spoon lex at cc.gatech.edu
Thu Nov 30 17:12:00 UTC 2006


Bert Freudenberg <bert at freudenbergs.de> writes:
> Not so in Smalltalk. As has been noted elsewhere, the compilation
> unit is a method in a class. Consequently, you need either fully
> qualified names, or have class-based imports. We already have a way
> to express the latter (class pools [*]), and we may like to have a
> way for the former. That's all.

That does sound onerous.  With an import list per method, you'd
probably end up with more than half your code being import statements!


However, suppose instead that a compilation unit was a package?  Most
imports would then be listed at the package level instead of the
method level.

Given this, you would then have two ways to find out the symbol, just
as in Java-land.  First, you could browse over to the definition of
the package.  Second--and in any scheme we devise--you could either
mouse over the identifier and see what pops up, or you could use
Squeak's cool "explain" feature.


-Lex







More information about the Squeak-dev mailing list