[Development] Raising the minimum to C++20

Marc Mutz marc.mutz at qt.io
Wed May 3 20:15:19 CEST 2023


On 03.05.23 18:03, Thiago Macieira wrote:
> On Tuesday, 2 May 2023 23:16:19 PDT Marc Mutz via Development wrote:
>> [1] I also heard the idea to make C++20 mandatory for building Qt, but
>> user projects could continue to use C++17. That would require _forward_
>> binary compatibility between stdlib implementations. Given that a C++20
>> stdlib must needs contain more symbols (C++20-only features), it's
>> almost guaranteed that forward BC isn't maintained by stdlibs.
> 
> I don't see that as a conclusion.
> 
> The library is the library. Whether you've compiled as C++14, 17, 20 or 23
> before linking to it is immaterial. What matters is the symbols it provides
> and the Standard Libraries must, by necessity, offer all the symbols that any
> compilation of their headers would require.
> 
> Upping our build requirements would allow us to offer symbols in our libraries
> that could only be accessed by code compiled under C++20. Right now, we can't
> do that and we must provide certain workarounds.

That might be so, and I'm not Maurice or Vladimir, but if I was to 
decide, I wouldn't commit my company to a roadmap that requires forward 
binary compatibility from stdlib vendors without a written declaration 
from each of them that this is a supported use-case.

-- 
Marc Mutz <marc.mutz at qt.io>
Principal Software Engineer

The Qt Company
Erich-Thilo-Str. 10 12489
Berlin, Germany
www.qt.io

Geschäftsführer: Mika Pälsi, Juha Varelius, Jouni Lintunen
Sitz der Gesellschaft: Berlin,
Registergericht: Amtsgericht Charlottenburg,
HRB 144331 B



More information about the Development mailing list