Naming Conventions & Style Guide?

Andrej Mitrovic andrej.mitrovich at gmail.com
Sun Jan 23 09:22:30 PST 2011


On 1/23/11, %u <wfunction at hotmail.com> wrote:
> Yeah, MMWV. :]

Men are from Mars, Women are from Venus? :D

I don't know what that abbreviation means.

I think some enums are in all caps because they're a workaround for
not being able to use e.g. "in" in a TypeTuple, so they're kind of
special. Specifically I saw that:

ParameterStorageClassTuple returns a Tuple with enum values that are
declared with all caps, while
ParameterTypeTuple returns actual types that you can use directly in a
new function signature.

That's just a guess though. Another guess is that they're in all caps
because they're directly related to the language itself. While
"LibraryEnum.EmailRegex" is unrelated to the language itself,
"ParameterStorageClass.REF" refers directly to a D feature, ref
parameters.

I'm only speculating, though.


More information about the Digitalmars-d-learn mailing list