On Sunday, 10 April 2016 at 22:03:54 UTC, Zekereth wrote:
So I was just testing some code and couldn't figure out why it wasn't working. My version block looked like this:

version(Linux)
{
...
}

Looking at the list(unless I'm missing something) Linux is the only OS that is lowercase. I'm guessing most people use Posix instead and never encounter this problem.


It's an artifact of history. When this was first introduced, Walter's intent was to match the casing used in gcc preprocessor definitions. Since that time, we've standardized on capitalization for everything, but 'linux' lives on. I would like to see 'Linux' introduced for consistency and to avoid errors like yours (a bug lived in Phobos for a long time because of this) while maintaining 'linux' for backwards compatibility.

Reply via email to