forked from qt-creator/qt-creator
CodeAssist: Initialize locals and member after early return.
Change-Id: Iec850ccbb6461b581fd2347006e6dfc8a0b605a7 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -223,13 +223,12 @@ void CodeAssistantPrivate::requestProposal(AssistReason reason,
|
||||
return;
|
||||
}
|
||||
|
||||
AssistInterface *assistInterface = m_editorWidget->createAssistInterface(kind, reason);
|
||||
if (!assistInterface)
|
||||
return;
|
||||
|
||||
m_assistKind = kind;
|
||||
IAssistProcessor *processor = provider->createProcessor();
|
||||
AssistInterface *assistInterface = m_editorWidget->createAssistInterface(kind, reason);
|
||||
if (!assistInterface) {
|
||||
delete processor;
|
||||
return;
|
||||
}
|
||||
|
||||
switch (provider->runType()) {
|
||||
case IAssistProvider::Synchronous: {
|
||||
|
||||
Reference in New Issue
Block a user