A little namespace "proposal"
Julian Fitzell
julian at beta4.com
Tue Apr 6 22:54:55 UTC 2004
Stéphane Rollandin wrote:
> Chris Muller wrote:
>
>>> this is very true ! personal testimony: in my development I wrote
>>> hundreds of classes, and I'm worried every time a simple obvious name
>>> comes to mind. so I end up prefixing everything with an ugly and
>>> meaningless SPFA (my initials), or taking the risk to name a class
>>> Silence (I'm into music composition)
>>
>>
>>
>> It's not meaningless because the name conveys that its your style, your
>> implementation, your solution to music-composition in a world where
>> there can
>> and should be hundreds of music-composition programs, even with lots of
>> overlapping functionality.
>>
>> When I see "MC" it tells me a ton about what to expect from that
>> software. Where else could you get so much utility out of two letters?
>>
>
> I understand your point. let's say that it is ugly and meaningless to
> *me*, when working on my own code, to be reminded every other word that
> *I* did write it. heavy ego trip !
Yes, exactly. The prefixes are only relevant to people outside the
package that they represent. Which is precisely the benefit of
namespaces: you don't need to use the "prefix" when you're working
within your own namespace. But the full name of the class (the full
name, including the prefix/namespace) still specifies exactly the same
information.
Julian
More information about the Squeak-dev
mailing list
|