D_Version2 problem

Sergey Gromov snake.scaly at gmail.com
Sun Jan 18 15:14:35 PST 2009


Sun, 18 Jan 2009 22:28:12 +0100, Hoenir wrote:

> The D_Version2 version identifier doesn't work properly for me.
> Tried compiling with dmd 1.039. D_Version2 is set even if I pass -v1 to it.
> 
> Is this a bug or am I doing something wrong?

Works for me.

It's hard to tell if you're doing something wrong until you post your
test code.

----8<------ test.d
version(D_Version2)
{
  pragma(msg, "v2");
}
else
{
  pragma(msg, "v1");
}
----8<------

> dmd -c test.d
v1


More information about the Digitalmars-d-learn mailing list