[Development] Qt 5 types under consideration for deprecation / removal in Qt 6
mardy at users.sourceforge.net
Tue Jun 18 22:56:36 CEST 2019
On 18/06/19 10:43, Mutz, Marc via Development wrote:
> On 2019-06-18 08:18, Alberto Mardegan wrote:
>> Adding a const bool operator to QSharedDataPointer would solve the
>> problem, wouldn't it?
> And (silently) break code that relies on the current behaviour, yes.
Well... Expecting the data to detach on an `if (d)` check seems worth
incurring into a breakage :-)
But I certainly cannot exclude that there is some code out there which
happens to work exactly because of this implicit detach, so it might be
better not touch this, after all.
> BTW: this is the proposed replacement of QSDP/QESDP for Qt-internal use:
> https://codereview.qt-project.org/c/qt/qtbase/+/115213 and no, it will
> most certainly _not_ be public API again. It's the fact that these
> implementation details of Qt, QSDP and QESDP, are public, that prevents
> us from fixing them. I will not be part of another such lock-in.
You won't, but someone else hopefully will, and shall have all my
I think you are overestimating the lock-in, here. The API surface of
these classes is relatively small; they have been used for over a
decade, with no major complaints. Yes, there are some issues, in some
places they are badly designed, but during these years the problems have
been noticed and now we have the chance to address them (with a
replacement as your proposed one, for example).
While I agree that these new classes shouldn't be made public right
away, using them internally in Qt should give us enough confidence that
they are an improvement over the S[E]QDP and we should be able to make
them public by Qt6.
Sure, it is possible that some new issues will be found after the Qt6
release, but given the size of these classes, and the fact that we have
more than a decade of experience using them (or a very similar API), how
likely is it that we screwed things up?
If a new bug should be found, that hasn't surfaced in all these years,
it's going to be a very, very minor issue.
http://www.mardy.it - Geek in un lingua international
More information about the Development