Update needed to binary compatibility guide for Windows?
Michael Pyne
mpyne at kde.org
Wed Apr 16 04:17:46 BST 2014
On Mon, April 14, 2014 18:28:14 Ian Monroe wrote:
> On Sun, Apr 13, 2014 at 6:36 PM, Michael Pyne <mpyne at kde.org> wrote:
> > If it's true, do we want
> > to adopt a constraint on our handling of virtual functions in leaf classes
> > based on this?
>
> IMO we shouldn't worry about ABI on Windows. And not because "meh
> Windows", but since Microsoft breaks C++ ABI with every compiler
> release, which is quite frequently these days. In general C++ ABI
> stability just isn't a thing on Windows.
I've looked it up and you're right, they don't even pretend to try to maintain
ABI compatibility (instead they recommend using an extern "C" wrapper or a COM
interface).
But at the same time we went through a time where GCC seemed to have to "fix"
their C++ ABI every release and we tried to maintain the same binary
compatibility standards throughout.
I think what I'll do is note the issue.
But in fact it may be worse: Do we require that applications never derive from
our exported classes? I.e. do we export interfaces (which should not be
derived from) or classes (which can be subclassed)?
Because if we export classes with virtual methods, and then an application
subclasses our class with their own virtual methods, then adding another
virtual method to our "most derived" exported class would break the
application even with the GCC ABI.
Regards,
- Michael Pyne
More information about the kde-core-devel
mailing list