Skip to content

Commit a56e8b8

Browse files
committed
Add missing capture to a lambda
1 parent 09f8104 commit a56e8b8

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

src/Parsers/CppParser/cppdocumentparser.cpp

+5-6
Original file line numberDiff line numberDiff line change
@@ -393,12 +393,11 @@ CppDocumentParser::CppDocumentParser( QObject* parent )
393393

394394
CppEditor::CppModelManager* modelManager = CppEditor::CppModelManager::instance();
395395
connect( modelManager, &CppEditor::CppModelManager::documentUpdated, this, &CppDocumentParser::parseCppDocumentOnUpdate, Qt::DirectConnection );
396-
connect( qApp, &QApplication::aboutToQuit, this, [=]() {
397-
/* Disconnect any signals that might still get emitted. */
398-
modelManager->disconnect( this );
399-
SpellCheckerCore::instance()->disconnect( this );
400-
this->disconnect( SpellCheckerCore::instance() );
401-
}, Qt::DirectConnection );
396+
connect( qApp, &QApplication::aboutToQuit, this, [=, this]() {
397+
/* Disconnect any signals that might still get emitted. */
398+
modelManager->disconnect( this );
399+
SpellCheckerCore::instance()->disconnect( this );
400+
this->disconnect( SpellCheckerCore::instance() ); }, Qt::DirectConnection );
402401

403402
Core::Context context( CppEditor::Constants::CPPEDITOR_ID );
404403
Core::ActionContainer* cppEditorContextMenu = Core::ActionManager::createMenu( CppEditor::Constants::M_CONTEXT );

0 commit comments

Comments
 (0)