https://bugs.kde.org/show_bug.cgi?id=457719
Bug ID: 457719 Summary: Incorrect warning [-Wclazy-incorrect-emit] Product: clazy Version: unspecified Platform: Other OS: Linux Status: REPORTED Severity: major Priority: NOR Component: general Assignee: unassigned-b...@kde.org Reporter: richard.oehlin...@adbsafegate.com CC: smart...@kde.org Target Milestone: --- SUMMARY Following code produces an incorrect emit warning: Emitting inside constructor probably has no effect [-Wclazy-incorrect-emit] When i change the connect to a pointer to method, the error doesn't occour. *** class MyClass : public QObject { Q_OBJECT public: void func(); signals: void mySignal(); }; void MyClass::func() { QNetworkReply* logout_reply = nullptr; QObject::connect(logout_reply, &QNetworkReply::finished, [] { }); emit mySignal(); } **** By the way IncorrectEmit::hasEmitKeyboard looks like a mis-spelling. -- You are receiving this mail because: You are watching all bug changes.