On Thursday, 3 July 2014 at 21:01:43 UTC, Jonathan M Davis via
Digitalmars-d wrote:

I'm fine with real varying from platform to platform depending on what makes sense for that platform, but I think that it should be clear what real is generally supposed to be (e.g. the largest floating point type that the hardware supports), but unless it's _guaranteed_ that real be the same as long double, I would strongly argue in favor of having an alias for long double rather than using real directly (much as it will likely be an alias to real in most cases). We already do that with c_long.

I'm inclined to agree.  From what's been said, I suspect that on
SPARC, 'real' would be an alias of 'double', and c_long_double
would be an alias of some intrinsic type provided by the
compiler, since there is no D equivalent for the IEEE 754
binary128 type.  The alternative, making c_long_double a struct
used for marshaling data into and out of the C format, doesn't
seem terribly appealing.

Reply via email to