LDC predefined identifiers

Brad Roberts braddr at puremagic.com
Mon Jun 8 09:19:33 PDT 2009


Leandro Lucarella wrote:
> Brad Roberts, el  7 de junio a las 18:53 me escribiste:
>> Frits van Bommel wrote:
>>> Brad Roberts wrote:
>>>> I'm in the process of updating the version.html list of predefined
>>>> identifiers.
>>>>  I'd like to include the identifiers that are produced by LDC as well as
>>>> validate that there aren't conflicts or contradictions between the
>>>> compilers.  I
>>>> know there was a thread about this a while back.  What's the current
>>>> state for LDC?
>>> Just search for "addPredefinedGlobalIdent" on this page:
>>> http://www.dsource.org/projects/ldc/browser/gen/main.cpp
>> Thanks.  I've added them.  I'm not particularly excited about the way this
>> looks, but take a peek:
>>
>> http://www.puremagic.com/~braddr/phobos-trunk/2.0/version.html#PredefinedVersions
> 
> I'm wondering if it's ok to include compiler-specific switches into the
> specs, isn't that against an specification? I guess it's better just to
> list the "standard" identifiers only and let compiler documentation list
> compiler specific ones.
> 
> I think the specs should be more and more compiler independent, not the
> other way around =)

I'm fine with dropping parts, this was a starting point.  On the table to drop
from the docs:

1) the entire Compiler Vendors block
2) darwin
3) freebsd
4) mingw32 ?
5) solaris

More?  Less?

My goal is to document what users should know about being able to write code
that will work with any D compiler.  Calling out the differences highlights
problem areas that exist today.

It's _ok_ that the predefined version identifiers don't line up 100%, that's to
be expected due to differences that don't cause grief.  For example, the cpu
architecture differences and the 32 vs 64 bit differences.

What's not ok is solaris vs Solaris (for example).  That just adds confusion.
I'm not going to be the guy to decide which is right.. the ldc developers and
walter can yell at each other until one caves.  But, please, one side cave so
there's just one.

Later,
Brad




More information about the Digitalmars-d mailing list