Conditional compilation for debug/release
Johan Engelen via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Mon Apr 6 07:50:27 PDT 2015
How do conditionally compile code for either release ("-release")
or debug ("-debug")?
Something like this:
version(Debug) {
pragma(lib, "libcmtd.lib");
} else {
pragma(lib, "libcmt.lib");
}
In the documentation [1], I don't see any predefined version
identifiers for this purpose.
Thanks,
Johan
[1] http://dlang.org/version.html
More information about the Digitalmars-d-learn
mailing list