Why is null lowercase?

Leandro Motta Barros lmb at stackedboxes.org
Thu Jan 24 05:24:18 PST 2013


Hi,

In C, NULL is a #define, and #defines are typically all-caps. In D,
null is real keyword recognized by the compiler, and those are
typically lowercase. I am just guessing here, but I'd say the choice
for 'null' instead of 'NULL' is just to be coherent with this.

Personally, I kinda like 'null'. :-)

LMB




On Thu, Jan 24, 2013 at 10:56 AM, Matthew Caron <matt.caron at redlion.net> wrote:
> This is probably a question for Walter, but maybe others know.
>
> Of all of the differences between C and D, the one which I have the most
> difficulty adapting to is null being lowercase. Does anyone know why this
> decision was made?
> --
> Matthew Caron, Software Build Engineer
> Sixnet, a Red Lion business | www.sixnet.com
> +1 (518) 877-5173 x138 office


More information about the Digitalmars-d-learn mailing list