Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
6.5
-
None
-
-
afddb327b (dev), fd6640006 (6.7), a40ca88b6 (6.6)
Description
Behavior breakage detected porting from Qt 6.2.3 to Qt 6.5.1:
QObject::connect(myObject, &Object::mySignal, context, [](){}, Qt::UniqueConnection);
Prior to Qt 6.5, the final parameter would be ignored / the connection would be established, but since the lambda is always unique I suppose the last argument made no sense.
From 6.5, a useful warning is printed!
WARNING: QObject::connect(<sender>, <receiver>): unique connections require a pointer to member function of a QObject subclass
But the connection is no longer established, which breaks behavior.
Attachments
Gerrit Reviews
For Gerrit Dashboard: QTBUG-115125 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
527564,1 | QObject: assert connection type isn't UniqueConnection for lambdas | tqtc/lts-6.5 | qt/tqtc-qtbase | Status: NEW | 0 | 0 |
511856,5 | QObject: assert connection type isn't UniqueConnection for lambdas | dev | qt/qtbase | Status: MERGED | +2 | 0 |
527535,2 | QObject: assert connection type isn't UniqueConnection for lambdas | 6.7 | qt/qtbase | Status: MERGED | +2 | 0 |
527552,2 | QObject: assert connection type isn't UniqueConnection for lambdas | 6.6 | qt/qtbase | Status: MERGED | +2 | 0 |