[Development] Use of std::function in Qt API
Ville Voutilainen
ville.voutilainen at gmail.com
Tue Mar 14 17:01:25 CET 2017
On 14 March 2017 at 17:54, Thiago Macieira <thiago.macieira at intel.com> wrote:
>> I understand that there are limitations (to put it mildly) regarding the use
>> of API from the C++ standard library in Qt API itself due to the inability
>> to extend our binary compatibility promise. I'm curious though whether
>> std::function falls under the same umbrella?
>
> It does. libstdc++ has shown they have no qualms about breaking binary
> compatibility in downstream libraries, as they've done it twice in the past
> three releases (the most notable case was std::string).
Ahem, it's not like there weren't qualms about it, but doing it for
std::string and std::list
was eventually necessary. The libstdc++ developers (including myself)
spend fair amounts
of time and energy trying to avoid abi breakage, including abi
breakage in downstream libraries.
> What we have to ask ourselves is whether we want to say that is not our
> problem. For example, the std::string breakage caused any application or
> library that used it in its API to need to be recompiled. Besides Qt, there
> aren't many libraries that avoid it. So if the underlying C++ Standard Library
> breaks ABI, should we try to work around it? Or should we punt the problem to
> the user?
I don't know. What do our users want? How big a problem would it be for them?
More information about the Development
mailing list