<div>I've researched MS ctor/dtor behaviour a bit, check PR 12784 (<a href="http://llvm.org/bugs/show_bug.cgi?id=12784">http://llvm.org/bugs/show_bug.cgi?id=12784</a>) for a simple file that shows the different types we will expect.</div>
<br><div class="gmail_quote">On Wed, Dec 5, 2012 at 2:28 PM, Timur Iskhodzhanov <span dir="ltr"><<a href="mailto:timurrrr@google.com" target="_blank">timurrrr@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On Tue, Dec 4, 2012 at 8:09 PM, Timur Iskhodzhanov <<a href="mailto:timurrrr@google.com">timurrrr@google.com</a>> wrote:<br>
>>> d) The complete/deleting dtor logic will change when we support MSVC<br>
>>> dtor types, but not now<br>
>>> [shouldn't matter now that we still don't support virtual inheritance]<br>
>><br>
>> You're thinking about complete vs. base destructors. Complete vs. deleting<br>
>> destructors isn't about virtual inheritance; it's about whether the destructor<br>
>> calls operator delete.<br>
> Yeah, now I see it... [see below]<br>
><br>
>> (This is important because the 'delete' operator uses<br>
>> the operator delete from the most-derived class.)<br>
>><br>
>> How does MSVC handle the difference between<br>
>> foo->~Foo(); // virtually dispatched but doesn't call operator delete<br>
>> and<br>
>> delete foo; // virtually dispatched and calls operator delete<br>
>> ?<br>
> Clang with my patch behaves badly on such code.<br>
> It seems to work fine at least on simple code where you don't use<br>
> virtual destructors.<br>
><br>
> Actually, the whole idea of base vs complete dtors doesn't apply to<br>
> -cxx-abi microsoft.<br>
> Anyways, had plans to work on ctor and dtor compatibility as a<br>
> separate patch - is that OK?<br>
> I've put a couple of more FIXME into the code for that. (in<br>
> ::AddMethod and ::ComputeMethodVTableIndices).<br>
<br>
</div>Attached is the patch which is similar to bug_13231_2 but puts the<br>
complete dtor rather than deleting.<br>
Both are basically broken anyways but at least you can choose what you<br>
think fits better :)<br>
Investigating compatible dtor behavior is definitely on my TODO-soon<br>
list now [as a separate change if this works]<br>
<br>_______________________________________________<br>
cfe-commits mailing list<br>
<a href="mailto:cfe-commits@cs.uiuc.edu">cfe-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Joćo Matos<br>