On 2014-01-12 19:47, Gary Willoughby wrote:
When using Win32/x86 in a version block, does that relate to the
compiler or OS?
for example:
version(Win32)
{
// 32bit Windows or 32bit Compiler?
}
Microsoft 32-bit Windows systems
version(X86)
{
// 32bit OS or 32bit Compiler?
}
Intel and AMD 32-bit processors
If these don't relate to the compiler is there any indication that the
program is being compiled with a 32bit compiler?
You might want to use: D_LP64 - Pointers are 64 bits (command line
switch -m64). (Do not confuse this with C's LP64 model)
I don't think what you're asking for is useful. The 32bit compiler can
compile both 32bit and 64bit code, at least DMD.
I'm primarily asking because i need to use this to constrain dub to
build different things depending on what compiler is used and on what
architecture.
DigitalMars - DMD
GNU - GDC
LDC - LDC
SDC - SDC
A complete list of predefined versions can be found here:
http://dlang.org/version.html#PredefinedVersions
--
/Jacob Carlborg