Details
-
Bug
-
Resolution: Duplicate
-
Not Evaluated
-
None
-
Qt Creator 4.14.0
-
None
Description
SUMMARY
When connecting to QAbstractItemView::entered signal, clazy doesn't recognize it as a signal.
STEPS TO REPRODUCE
1. Subclass a QTreeWidget
2. In the constructor, connect to the ::entered signal using something like this:
connect(this, &QTreeWidget::entered, this, []{});
//or//
connect(this, &QAbstractItemView::entered, this, []{});
(it doesn't have to be a lambda for the slot)
3. Run clazy within QtCreator
OBSERVED RESULT
Clazy warns that the ::entered signal is not a signal
EXPECTED RESULT
Clazy recognizes the ::entered signal as a signal and no warning is given
ADDITIONAL INFO
I get the same "...is not a signal [clazy-connect-non-signal]" warning when connecting to all of these signals that are inherited from QAbstractItemView
connect(this, &QTreeWidget::entered, this, []{});
connect(this, &QTreeWidget::pressed, this, []{});
connect(this, &QTreeWidget::viewportEntered, this, []{});
connect(this, &QTreeWidget::activated, this, []{});
connect(this, &QTreeWidget::clicked, this, []{});
as well as from these signals inherited from QTreeView:
connect(this, &QTreeWidget::collapsed, this, []{});
connect(this, &QTreeWidget::expanded, this, []{});
but NOT from any of these signals inherited from QTreeWidget:
connect(this, &QTreeWidget::itemEntered, this, []{});
connect(this, &QTreeWidget::itemExpanded, this, []{});
connect(this, &QTreeWidget::itemPressed, this, []{});
connect(this, &QTreeWidget::currentItemChanged, this, []{});
connect(this, &QTreeWidget::itemSelectionChanged, this, []{});
Attachments
Issue Links
- duplicates
-
QTCREATORBUG-25165 clazy-connect-non-signal mis-reporting
- Closed