Manifest constants (was const again)

Derek Parnell derek at psych.ward
Sat Dec 8 14:41:57 PST 2007


On Sat, 08 Dec 2007 11:16:27 -0800, Walter Bright wrote:

> Derek Parnell wrote:
>> On Sat, 08 Dec 2007 01:01:27 -0800, Walter Bright wrote:
>> 
>>> With the enum case, I doubt it would take more than a moment for someone 
>>> to figure out what it was, and it is not confusingly similar to 
>>> something else. Once one knows what it is, one might take a moment to 
>>> ridicule the choice of keyword, but that's about it before getting past 
>>> it and it becoming just more D jargon like static, class, and real.
>> 
>> True and sad. Another opportunity to "do the right thing" missed.
> 
> C'mon, it's not that big a deal!

One can tell that from the reaction, no? As your suggestion has generated
almost zero comment then it must be a small deal. 

In any case, the point is not so much how you see the size of the deal, but
how your customer's do. My reading of the situation so far is that it
struck instant and vocal opposition. The group of people in support have
been quiet in comparison. Also, I feel it is especially significant that
many of the people who have suggested that 'enum' is a poorer choice are
not from the "usual suspects" set.

>> WILL THE NEW ENUM BE ALLOWED TO GROUP MANIFEST CONSTANTS TOGETHER?
> 
> No.

I take it that you are not so enamored with the school of thought that
believes compilers exist to make life easier for coders. This keeps coming
through in the mixed messages. You seem to want D to be an improvement over
the foibles of C/C++ yet you have introduced a few constructs that are
their own new foibles.

This one for example, means that redundant code will be needed and it has
the potential to make reading source more difficult that it needs to be.
 
So I repeat myself ... Another opportunity to "do the right thing" missed.

-- 
Derek Parnell
Melbourne, Australia
skype: derek.j.parnell



More information about the Digitalmars-d mailing list