C++ interop - what to do about long and unsigned long?
Iain Buclaw via Digitalmars-d
digitalmars-d at puremagic.com
Wed Sep 10 23:26:55 PDT 2014
On 10 September 2014 21:40, Walter Bright via Digitalmars-d
<digitalmars-d at puremagic.com> wrote:
> C++'s long and unsigned long can be accessed with c_long and c_ulong.
> Unfortunately, these are aliases and mangle to their underlying types.
>
This problem is not lost on me (and hopefully Daniel).
>
> 2. create full fledged types __c_long and __c_ulong, and alias c_long and
> c_ulong to them.
>
This is not unreasonable. And would allow dmd to fix their whole C++
long/ulong mangling mess.
>
> The same issue exists for C++'s 'long double'.
I don't think so, as there is 'real' for that.
Iain.
More information about the Digitalmars-d
mailing list