A little namespace "proposal"
Dan Ingalls
Dan at SqueakLand.org
Wed Apr 14 21:00:36 UTC 2004
>I like the email of lex. Now I do not really understand why there is something wrong with the following code
>
>I prefer to show code that write names since we all have a different understanding of them ;)
>
>Tweak namespace new
> import: MorphWithExtraLongName from: Morphic
> import: Scheduler from: Kernel;
> import: lkjlkjl from: Grrrrr;
>
>MorphiWithExtraLongName subclass: #MyWonderderfullClass
> ...
>
>MyWonderfullClass>>myWonderfulMethod
> ....
> Scheduler start
Hi, Stef -
Thanks for the concrete example.
Does the first line declare the following imports as part of a namespace named 'Tweak', or are we creating an as-yet-unnamed namespace by sending a message to a global object Tweak (like Smalltalk)? If the former, the I was expecting something easier to execute (ie receiver doesn't start out undefined) like
Namespace new named: 'Tweak'
If I were writing myWonderfulMethod and accepting it for the first time, would the programmer's assistant offer up a menu like...
"Scheduler is not defined in this namespace..."
| import from Kernel
| import from NewSchedTest
| ----------------------
| declare local
| declare global
| leave undeclared
If so it would be fairly consistent with what we have now.
- Dan
More information about the Squeak-dev
mailing list
|