[Issue 14203] New: Return of floating point values from extern(C++) member functions does not match dmc

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Thu Feb 19 18:37:29 PST 2015


https://issues.dlang.org/show_bug.cgi?id=14203

          Issue ID: 14203
           Summary: Return of floating point values from extern(C++)
                    member functions does not match dmc
           Product: D
           Version: D2
          Hardware: x86
                OS: Windows
            Status: NEW
          Keywords: C++, wrong-code
          Severity: major
          Priority: P1
         Component: DMD
          Assignee: nobody at puremagic.com
          Reporter: yebblies at gmail.com

struct C
{
    float func() { return 0; }
};

The C++ version of this code returns via the stack, but the D version returns
in ST(0).  One of these is obviously wrong.

Same for double and real/long double, only on win32.

I don't know if this is a bug in dmd or dmc.  Anyone?

--


More information about the Digitalmars-d-bugs mailing list