January 22, 2016
On 1/19/2016 6:02 AM, Manu via Digitalmars-d wrote:
> On 19 January 2016 at 22:36, Andrei Alexandrescu via Digitalmars-d
> <digitalmars-d@puremagic.com> wrote:
>>
>> Is there an open issue? -- Andrei
>
> There is: https://issues.dlang.org/show_bug.cgi?id=15579
>

https://github.com/D-Programming-Language/dmd/pull/5361

Unfortunately, that doesn't completely fix Win64, I'll follow up with one that does.
January 23, 2016
On 23 January 2016 at 06:25, Walter Bright via Digitalmars-d <digitalmars-d@puremagic.com> wrote:
> On 1/19/2016 6:02 AM, Manu via Digitalmars-d wrote:
>>
>> On 19 January 2016 at 22:36, Andrei Alexandrescu via Digitalmars-d <digitalmars-d@puremagic.com> wrote:
>>>
>>>
>>> Is there an open issue? -- Andrei
>>
>>
>> There is: https://issues.dlang.org/show_bug.cgi?id=15579
>>
>
> https://github.com/D-Programming-Language/dmd/pull/5361
>
> Unfortunately, that doesn't completely fix Win64, I'll follow up with one that does.

I brought a work laptop home this weekend in anticipation ;)
January 24, 2016
On 1/22/2016 5:46 PM, Manu via Digitalmars-d wrote:
> I brought a work laptop home this weekend in anticipation ;)

Here ya go:

  https://github.com/D-Programming-Language/dmd/pull/5364

Be wary of:

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

and use the workaround as necessary. This is lower priority, so I won't be dealing with it for a bit.
January 26, 2016
On 24 January 2016 at 20:40, Walter Bright via Digitalmars-d <digitalmars-d@puremagic.com> wrote:
> On 1/22/2016 5:46 PM, Manu via Digitalmars-d wrote:
>>
>> I brought a work laptop home this weekend in anticipation ;)
>
>
> Here ya go:
>
>   https://github.com/D-Programming-Language/dmd/pull/5364
>
> Be wary of:
>
>   https://issues.dlang.org/show_bug.cgi?id=15589
>
> and use the workaround as necessary. This is lower priority, so I won't be dealing with it for a bit.

Next blocker: https://issues.dlang.org/show_bug.cgi?id=15610

C++ methods with multiple-inheritence expect that 'this' is a pointer
to the base class that introduced the function.
When using C++ 'interface's, which C++ just treats like normal
multiple-inheritence, C++ expects that the 'this' pointer is adjusted
to the offset of the interface's vtable.

If I have:
extern(C++) interface Interface { voif f(); }
extern(C++) class C : Base, Interface
{
  void f();
}

Calling c.f(), D is passing 'this' unaltered, but C++ expects 'this' is a pointer to 'Interface', and then it crashes accessing members at incorrect offsets.
January 26, 2016
On 26 January 2016 at 15:02, Manu <turkeyman@gmail.com> wrote:
> On 24 January 2016 at 20:40, Walter Bright via Digitalmars-d <digitalmars-d@puremagic.com> wrote:
>> On 1/22/2016 5:46 PM, Manu via Digitalmars-d wrote:
>>>
>>> I brought a work laptop home this weekend in anticipation ;)
>>
>>
>> Here ya go:
>>
>>   https://github.com/D-Programming-Language/dmd/pull/5364
>>
>> Be wary of:
>>
>>   https://issues.dlang.org/show_bug.cgi?id=15589
>>
>> and use the workaround as necessary. This is lower priority, so I won't be dealing with it for a bit.
>
> Next blocker: https://issues.dlang.org/show_bug.cgi?id=15610
>
> C++ methods with multiple-inheritence expect that 'this' is a pointer
> to the base class that introduced the function.
> When using C++ 'interface's, which C++ just treats like normal
> multiple-inheritence, C++ expects that the 'this' pointer is adjusted
> to the offset of the interface's vtable.
>
> If I have:
> extern(C++) interface Interface { voif f(); }
> extern(C++) class C : Base, Interface
> {
>   void f();
> }
>
> Calling c.f(), D is passing 'this' unaltered, but C++ expects 'this' is a pointer to 'Interface', and then it crashes accessing members at incorrect offsets.

Also, bugs in the name mangling are really becoming a problem. I have logged several bugs of this sort, but my code has developed a serious case of pragma(mangle, "??XYZ.....") appearing all over the place to make it link.

https://issues.dlang.org/show_bug.cgi?id=15608 https://issues.dlang.org/show_bug.cgi?id=15576 https://issues.dlang.org/show_bug.cgi?id=15473

This is not a blocker, but I think it's high priority.
January 25, 2016
On 1/25/2016 9:02 PM, Manu via Digitalmars-d wrote:
> On 24 January 2016 at 20:40, Walter Bright via Digitalmars-d
> <digitalmars-d@puremagic.com> wrote:
>> On 1/22/2016 5:46 PM, Manu via Digitalmars-d wrote:
>>>
>>> I brought a work laptop home this weekend in anticipation ;)
>>
>>
>> Here ya go:
>>
>>    https://github.com/D-Programming-Language/dmd/pull/5364
>>
>> Be wary of:
>>
>>    https://issues.dlang.org/show_bug.cgi?id=15589
>>
>> and use the workaround as necessary. This is lower priority, so I won't be
>> dealing with it for a bit.
>
> Next blocker: https://issues.dlang.org/show_bug.cgi?id=15610
>
> C++ methods with multiple-inheritence expect that 'this' is a pointer
> to the base class that introduced the function.
> When using C++ 'interface's, which C++ just treats like normal
> multiple-inheritence, C++ expects that the 'this' pointer is adjusted
> to the offset of the interface's vtable.
>
> If I have:
> extern(C++) interface Interface { voif f(); }
> extern(C++) class C : Base, Interface
> {
>    void f();
> }
>
> Calling c.f(), D is passing 'this' unaltered, but C++ expects 'this'
> is a pointer to 'Interface', and then it crashes accessing members at
> incorrect offsets.
>

The PR 5364 does this. (And only Microsoft Win64 has this effect.)
January 26, 2016
On 26 January 2016 at 15:11, Walter Bright via Digitalmars-d <digitalmars-d@puremagic.com> wrote:
> On 1/25/2016 9:02 PM, Manu via Digitalmars-d wrote:
>>
>> On 24 January 2016 at 20:40, Walter Bright via Digitalmars-d <digitalmars-d@puremagic.com> wrote:
>>>
>>> On 1/22/2016 5:46 PM, Manu via Digitalmars-d wrote:
>>>>
>>>>
>>>> I brought a work laptop home this weekend in anticipation ;)
>>>
>>>
>>>
>>> Here ya go:
>>>
>>>    https://github.com/D-Programming-Language/dmd/pull/5364
>>>
>>> Be wary of:
>>>
>>>    https://issues.dlang.org/show_bug.cgi?id=15589
>>>
>>> and use the workaround as necessary. This is lower priority, so I won't
>>> be
>>> dealing with it for a bit.
>>
>>
>> Next blocker: https://issues.dlang.org/show_bug.cgi?id=15610
>>
>> C++ methods with multiple-inheritence expect that 'this' is a pointer
>> to the base class that introduced the function.
>> When using C++ 'interface's, which C++ just treats like normal
>> multiple-inheritence, C++ expects that the 'this' pointer is adjusted
>> to the offset of the interface's vtable.
>>
>> If I have:
>> extern(C++) interface Interface { voif f(); }
>> extern(C++) class C : Base, Interface
>> {
>>    void f();
>> }
>>
>> Calling c.f(), D is passing 'this' unaltered, but C++ expects 'this' is a pointer to 'Interface', and then it crashes accessing members at incorrect offsets.
>>
>
> The PR 5364 does this. (And only Microsoft Win64 has this effect.)

Oh okay. I thought that PR was about correctly locating the vtable and function offsets. I'll wait till that's merged.
January 26, 2016
On 26 January 2016 at 15:20, Manu <turkeyman@gmail.com> wrote:
> On 26 January 2016 at 15:11, Walter Bright via Digitalmars-d <digitalmars-d@puremagic.com> wrote:
>> On 1/25/2016 9:02 PM, Manu via Digitalmars-d wrote:
>>>
>>> On 24 January 2016 at 20:40, Walter Bright via Digitalmars-d <digitalmars-d@puremagic.com> wrote:
>>>>
>>>> On 1/22/2016 5:46 PM, Manu via Digitalmars-d wrote:
>>>>>
>>>>>
>>>>> I brought a work laptop home this weekend in anticipation ;)
>>>>
>>>>
>>>>
>>>> Here ya go:
>>>>
>>>>    https://github.com/D-Programming-Language/dmd/pull/5364
>>>>
>>>> Be wary of:
>>>>
>>>>    https://issues.dlang.org/show_bug.cgi?id=15589
>>>>
>>>> and use the workaround as necessary. This is lower priority, so I won't
>>>> be
>>>> dealing with it for a bit.
>>>
>>>
>>> Next blocker: https://issues.dlang.org/show_bug.cgi?id=15610
>>>
>>> C++ methods with multiple-inheritence expect that 'this' is a pointer
>>> to the base class that introduced the function.
>>> When using C++ 'interface's, which C++ just treats like normal
>>> multiple-inheritence, C++ expects that the 'this' pointer is adjusted
>>> to the offset of the interface's vtable.
>>>
>>> If I have:
>>> extern(C++) interface Interface { voif f(); }
>>> extern(C++) class C : Base, Interface
>>> {
>>>    void f();
>>> }
>>>
>>> Calling c.f(), D is passing 'this' unaltered, but C++ expects 'this' is a pointer to 'Interface', and then it crashes accessing members at incorrect offsets.
>>>
>>
>> The PR 5364 does this. (And only Microsoft Win64 has this effect.)
>
> Oh okay. I thought that PR was about correctly locating the vtable and function offsets. I'll wait till that's merged.
January 26, 2016
On 26 January 2016 at 15:20, Manu <turkeyman@gmail.com> wrote:
> On 26 January 2016 at 15:11, Walter Bright via Digitalmars-d
>>
>> The PR 5364 does this. (And only Microsoft Win64 has this effect.)
>
> Oh okay. I thought that PR was about correctly locating the vtable and function offsets. I'll wait till that's merged.

I tried to build DMD myself, doesn't build with vs2015: https://issues.dlang.org/show_bug.cgi?id=15611

*sigh* .. everything's always so hard! It's exhausting.
January 26, 2016
On 26/01/2016 5:29 PM, Manu via Digitalmars-d wrote:
>
> I tried to build DMD myself, doesn't build with vs2015:
> https://issues.dlang.org/show_bug.cgi?id=15611
>
> *sigh* .. everything's always so hard! It's exhausting.
>

Get with the times, vs2015 is so last year.