Commit e2ce17ef authored by Nikolai Kosjar's avatar Nikolai Kosjar
Browse files

CppTools: Fix "! condition" coding style



Change-Id: Ic7e634e4249fb64edbc2daceb65ec8e9b5f0f8b9
Reviewed-by: Orgad Shaneh's avatarOrgad Shaneh <orgads@gmail.com>
Reviewed-by: default avatarAurindam Jana <aurindam.jana@digia.com>
parent 782b9994
......@@ -59,7 +59,7 @@ static void parse(QFutureInterface<void> &future,
const bool isSourceFile = i < sourceCount;
if (isSourceFile) {
(void) preproc->run(conf);
} else if (! processingHeaders) {
} else if (!processingHeaders) {
(void) preproc->run(conf);
processingHeaders = true;
......@@ -182,7 +182,7 @@ QFuture<void> BuiltinIndexingSupport::refreshSourceFiles(const QStringList &sour
m_synchronizer.clearFutures();
foreach (const QFuture<void> &future, futures) {
if (! (future.isFinished() || future.isCanceled()))
if (!(future.isFinished() || future.isCanceled()))
m_synchronizer.addFuture(future);
}
}
......
......@@ -94,9 +94,9 @@ public:
protected:
void process(Document::Ptr doc, QSet<Namespace *> *processed)
{
if (! doc)
if (!doc)
return;
if (! processed->contains(doc->globalNamespace())) {
if (!processed->contains(doc->globalNamespace())) {
processed->insert(doc->globalNamespace());
foreach (const Document::Include &i, doc->includes())
......@@ -115,7 +115,7 @@ protected:
void addType(const Name *name)
{
if (! name) {
if (!name) {
return;
} else if (const QualifiedNameId *q = name->asQualifiedNameId()) {
......@@ -130,7 +130,7 @@ protected:
void addField(const Name *name)
{
if (! name) {
if (!name) {
return;
} else if (name->isNameId()) {
......@@ -142,7 +142,7 @@ protected:
void addFunction(const Name *name)
{
if (! name) {
if (!name) {
return;
} else if (name->isNameId()) {
......@@ -153,7 +153,7 @@ protected:
void addStatic(const Name *name)
{
if (! name) {
if (!name) {
return;
} else if (name->isNameId() || name->isTemplateNameId()) {
......@@ -196,7 +196,7 @@ protected:
if (symbol->isTypedef())
addType(symbol->name());
else if (! symbol->type()->isFunctionType() && symbol->enclosingScope()->isClass())
else if (!symbol->type()->isFunctionType() && symbol->enclosingScope()->isClass())
addField(symbol->name());
return true;
......@@ -333,7 +333,7 @@ void CheckSymbols::run()
qSort(_macroUses.begin(), _macroUses.end(), sortByLinePredicate);
_doc->clearDiagnosticMessages();
if (! isCanceled()) {
if (!isCanceled()) {
if (_doc->translationUnit()) {
accept(_doc->translationUnit()->ast());
_usages << QVector<Result>::fromList(_macroUses);
......@@ -473,7 +473,7 @@ bool CheckSymbols::visit(NamespaceAST *ast)
{
if (ast->identifier_token) {
const Token &tok = tokenAt(ast->identifier_token);
if (! tok.generated()) {
if (!tok.generated()) {
unsigned line, column;
getTokenStartPosition(ast->identifier_token, &line, &column);
Result use(line, column, tok.length(), CppHighlightingSupport::TypeUse);
......@@ -499,7 +499,7 @@ bool CheckSymbols::visit(SimpleDeclarationAST *ast)
{
NameAST *declrIdNameAST = 0;
if (ast->declarator_list && !ast->declarator_list->next) {
if (ast->symbols && ! ast->symbols->next && !ast->symbols->value->isGenerated()) {
if (ast->symbols && !ast->symbols->next && !ast->symbols->value->isGenerated()) {
Symbol *decl = ast->symbols->value;
if (NameAST *nameAST = declaratorId(ast->declarator_list->value)) {
if (Function *funTy = decl->type()->asFunctionType()) {
......@@ -559,7 +559,7 @@ bool CheckSymbols::visit(ElaboratedTypeSpecifierAST *ast)
bool CheckSymbols::visit(MemberAccessAST *ast)
{
accept(ast->base_expression);
if (! ast->member_name)
if (!ast->member_name)
return false;
if (const Name *name = ast->member_name->name) {
......@@ -711,7 +711,7 @@ QByteArray CheckSymbols::textOf(AST *ast) const
void CheckSymbols::checkNamespace(NameAST *name)
{
if (! name)
if (!name)
return;
unsigned line, column;
......@@ -730,13 +730,13 @@ void CheckSymbols::checkNamespace(NameAST *name)
bool CheckSymbols::hasVirtualDestructor(Class *klass) const
{
if (! klass)
if (!klass)
return false;
const Identifier *id = klass->identifier();
if (! id)
if (!id)
return false;
for (Symbol *s = klass->find(id); s; s = s->next()) {
if (! s->name())
if (!s->name())
continue;
if (s->name()->isDestructorNameId()) {
if (Function *funTy = s->type()->asFunctionType()) {
......@@ -754,9 +754,9 @@ bool CheckSymbols::hasVirtualDestructor(ClassOrNamespace *binding) const
QList<ClassOrNamespace *> todo;
todo.append(binding);
while (! todo.isEmpty()) {
while (!todo.isEmpty()) {
ClassOrNamespace *b = todo.takeFirst();
if (b && ! processed.contains(b)) {
if (b && !processed.contains(b)) {
processed.insert(b);
foreach (Symbol *s, b->symbols()) {
if (Class *k = s->asClass()) {
......@@ -775,7 +775,7 @@ bool CheckSymbols::hasVirtualDestructor(ClassOrNamespace *binding) const
void CheckSymbols::checkName(NameAST *ast, Scope *scope)
{
if (ast && ast->name) {
if (! scope)
if (!scope)
scope = enclosingScope();
if (ast->asDestructorName() != 0) {
......@@ -796,7 +796,7 @@ void CheckSymbols::checkName(NameAST *ast, Scope *scope)
}
}
} else if (maybeType(ast->name) || maybeStatic(ast->name)) {
if (! maybeAddTypeOrStatic(_context.lookup(ast->name, scope), ast)) {
if (!maybeAddTypeOrStatic(_context.lookup(ast->name, scope), ast)) {
// it can be a local variable
if (maybeField(ast->name))
maybeAddField(_context.lookup(ast->name, scope), ast);
......@@ -895,7 +895,7 @@ ClassOrNamespace *CheckSymbols::checkNestedName(QualifiedNameAST *ast)
}
accept(template_id->template_argument_list);
if (! binding)
if (!binding)
continue;
}
......@@ -1026,7 +1026,7 @@ bool CheckSymbols::visit(FunctionDefinitionAST *ast)
_astStack.append(thisFunction);
bool processEntireDeclr = true;
if (ast->declarator && ast->symbol && ! ast->symbol->isGenerated()) {
if (ast->declarator && ast->symbol && !ast->symbol->isGenerated()) {
Function *fun = ast->symbol;
if (NameAST *declId = declaratorId(ast->declarator)) {
processEntireDeclr = false;
......@@ -1077,7 +1077,7 @@ bool CheckSymbols::visit(FunctionDefinitionAST *ast)
void CheckSymbols::addUse(NameAST *ast, Kind kind)
{
if (! ast)
if (!ast)
return;
if (QualifiedNameAST *q = ast->asQualifiedName())
......@@ -1085,7 +1085,7 @@ void CheckSymbols::addUse(NameAST *ast, Kind kind)
if (DestructorNameAST *dtor = ast->asDestructorName())
ast = dtor->unqualified_name;
if (! ast)
if (!ast)
return; // nothing to do
else if (ast->asOperatorFunctionId() != 0 || ast->asConversionFunctionId() != 0)
return; // nothing to do
......@@ -1100,7 +1100,7 @@ void CheckSymbols::addUse(NameAST *ast, Kind kind)
void CheckSymbols::addUse(unsigned tokenIndex, Kind kind)
{
if (! tokenIndex)
if (!tokenIndex)
return;
const Token &tok = tokenAt(tokenIndex);
......@@ -1120,7 +1120,7 @@ void CheckSymbols::addUse(const Result &use)
if (use.isInvalid())
return;
if (! enclosingFunctionDefinition()) {
if (!enclosingFunctionDefinition()) {
if (_usages.size() >= _chunkSize) {
if (use.line > _lineOfLastUsage)
flush();
......@@ -1137,7 +1137,7 @@ void CheckSymbols::addUse(const Result &use)
void CheckSymbols::addType(ClassOrNamespace *b, NameAST *ast)
{
unsigned startToken;
if (! b || !acceptName(ast, &startToken))
if (!b || !acceptName(ast, &startToken))
return;
const Token &tok = tokenAt(startToken);
......@@ -1218,11 +1218,11 @@ bool CheckSymbols::maybeAddField(const QList<LookupItem> &candidates, NameAST *a
foreach (const LookupItem &r, candidates) {
Symbol *c = r.declaration();
if (! c)
if (!c)
continue;
else if (! c->isDeclaration())
else if (!c->isDeclaration())
return false;
else if (! (c->enclosingScope() && c->enclosingScope()->isClass()))
else if (!(c->enclosingScope() && c->enclosingScope()->isClass()))
return false; // shadowed
else if (c->isTypedef() || (c->type() && c->type()->isFunctionType()))
return false; // shadowed
......@@ -1261,7 +1261,7 @@ bool CheckSymbols::maybeAddFunction(const QList<LookupItem> &candidates, NameAST
Symbol *c = r.declaration();
// Skip current if there's no declaration or name.
if (! c || !c->name())
if (!c || !c->name())
continue;
// In addition check for destructors, since the leading ~ is not taken into consideration.
......@@ -1272,13 +1272,13 @@ bool CheckSymbols::maybeAddFunction(const QList<LookupItem> &candidates, NameAST
isConstructor = isConstructorDeclaration(c);
Function *funTy = c->type()->asFunctionType();
if (! funTy) {
if (!funTy) {
//Try to find a template function
if (Template * t = r.type()->asTemplateType())
if ((c = t->declaration()))
funTy = c->type()->asFunctionType();
}
if (! funTy)
if (!funTy)
continue; // TODO: add diagnostic messages and color call-operators calls too?
if (argumentCount < funTy->minimumArgumentCount()) {
......@@ -1286,7 +1286,7 @@ bool CheckSymbols::maybeAddFunction(const QList<LookupItem> &candidates, NameAST
kind = funTy->isVirtual() ? CppHighlightingSupport::VirtualMethodUse : CppHighlightingSupport::FunctionUse;
matchType = Match_TooFewArgs;
}
} else if (argumentCount > funTy->argumentCount() && ! funTy->isVariadic()) {
} else if (argumentCount > funTy->argumentCount() && !funTy->isVariadic()) {
if (matchType != Match_Ok) {
matchType = Match_TooManyArgs;
kind = funTy->isVirtual() ? CppHighlightingSupport::VirtualMethodUse : CppHighlightingSupport::FunctionUse;
......
......@@ -210,7 +210,7 @@ static void configureOverviewWithCodeStyleSettings(CPlusPlus::Overview &overview
CPlusPlus::Overview CppCodeStyleSettings::currentProjectCodeStyleOverview()
{
ProjectExplorer::Project *project = ProjectExplorer::ProjectExplorerPlugin::currentProject();
if (! project)
if (!project)
return currentGlobalCodeStyleOverview();
ProjectExplorer::EditorConfiguration *editorConfiguration = project->editorConfiguration();
......
......@@ -1498,7 +1498,7 @@ void CppToolsPlugin::test_completion_typedef_of_type_and_decl_of_type_no_replace
QCOMPARE(completions.size(), 2);
QVERIFY(completions.contains(QLatin1String("S")));
QVERIFY(completions.contains(QLatin1String("m")));
QVERIFY(! replaceAccessOperator);
QVERIFY(!replaceAccessOperator);
}
void CppToolsPlugin::test_completion_typedef_of_pointer_and_decl_of_pointer_no_replace_access_operator()
......@@ -1524,7 +1524,7 @@ void CppToolsPlugin::test_completion_typedef_of_pointer_and_decl_of_pointer_no_r
QStringList completions = getCompletions(data, &replaceAccessOperator);
QCOMPARE(completions.size(), 0);
QVERIFY(! replaceAccessOperator);
QVERIFY(!replaceAccessOperator);
}
void CppToolsPlugin::test_completion_typedef_of_type_and_decl_of_pointer_replace_access_operator()
......@@ -1636,7 +1636,7 @@ void CppToolsPlugin::test_completion_predecl_typedef_of_type_and_decl_type_no_re
QCOMPARE(completions.size(), 2);
QVERIFY(completions.contains(QLatin1String("S")));
QVERIFY(completions.contains(QLatin1String("m")));
QVERIFY(! replaceAccessOperator);
QVERIFY(!replaceAccessOperator);
}
void CppToolsPlugin::test_completion_predecl_typedef_of_pointer_and_decl_of_pointer_no_replace_access_operator()
......@@ -1662,7 +1662,7 @@ void CppToolsPlugin::test_completion_predecl_typedef_of_pointer_and_decl_of_poin
QStringList completions = getCompletions(data, &replaceAccessOperator);
QCOMPARE(completions.size(), 0);
QVERIFY(! replaceAccessOperator);
QVERIFY(!replaceAccessOperator);
}
void CppToolsPlugin::test_completion_predecl_typedef_of_pointer_and_decl_of_type_replace_access_operator()
......
......@@ -218,7 +218,9 @@ void CppAssistProposalItem::applyContextualContent(TextEditor::BaseTextEditor *e
if (Function *function = symbol->type()->asFunctionType()) {
// If the member is a function, automatically place the opening parenthesis,
// except when it might take template parameters.
if (! function->hasReturnType() && (function->unqualifiedName() && !function->unqualifiedName()->isDestructorNameId())) {
if (!function->hasReturnType()
&& (function->unqualifiedName()
&& !function->unqualifiedName()->isDestructorNameId())) {
// Don't insert any magic, since the user might have just wanted to select the class
/// ### port me
......@@ -228,7 +230,7 @@ void CppAssistProposalItem::applyContextualContent(TextEditor::BaseTextEditor *e
if (function->argumentCount() == 0)
extraChars += QLatin1Char('<');
#endif
} else if (!isDereferenced(editor, basePosition) && ! function->isAmbiguous()) {
} else if (!isDereferenced(editor, basePosition) && !function->isAmbiguous()) {
// When the user typed the opening parenthesis, he'll likely also type the closing one,
// in which case it would be annoying if we put the cursor after the already automatically
// inserted closing parenthesis.
......@@ -253,7 +255,7 @@ void CppAssistProposalItem::applyContextualContent(TextEditor::BaseTextEditor *e
}
// If the function takes no arguments, automatically place the closing parenthesis
if (!isOverloaded() && ! function->hasArguments() && skipClosingParenthesis) {
if (!isOverloaded() && !function->hasArguments() && skipClosingParenthesis) {
extraChars += QLatin1Char(')');
if (endWithSemicolon) {
extraChars += semicolon;
......@@ -392,7 +394,7 @@ int CppFunctionHintModel::activeArgument(const QString &prefix) const
++parcount;
else if (tk.is(T_RPAREN))
--parcount;
else if (! parcount && tk.is(T_COMMA))
else if (!parcount && tk.is(T_COMMA))
++argnr;
}
......@@ -504,8 +506,8 @@ public:
BasicProposalItem *operator()(Symbol *symbol)
{
//using declaration can be qualified
if (! symbol || ! symbol->name() || (symbol->name()->isQualifiedNameId()
&& ! symbol->asUsingDeclaration()))
if (!symbol || !symbol->name() || (symbol->name()->isQualifiedNameId()
&& !symbol->asUsingDeclaration()))
return 0;
BasicProposalItem *previousItem = switchCompletionItem(0);
......@@ -986,7 +988,7 @@ bool CppCompletionAssistProcessor::tryObjCCompletion()
const QString expr = m_interface->textAt(startPos, m_interface->position() - startPos);
Document::Ptr thisDocument = m_interface->snapshot().document(m_interface->fileName());
if (! thisDocument)
if (!thisDocument)
return false;
m_model->m_typeOfExpression->init(thisDocument, m_interface->snapshot());
......@@ -1205,7 +1207,7 @@ int CppCompletionAssistProcessor::startCompletionInternal(const QString fileName
QString expression = expr.trimmed();
Document::Ptr thisDocument = m_interface->snapshot().document(fileName);
if (! thisDocument)
if (!thisDocument)
return -1;
m_model->m_typeOfExpression->init(thisDocument, m_interface->snapshot());
......@@ -1234,7 +1236,7 @@ int CppCompletionAssistProcessor::startCompletionInternal(const QString fileName
if (results.isEmpty()) {
if (m_model->m_completionOperator == T_SIGNAL || m_model->m_completionOperator == T_SLOT) {
if (! (expression.isEmpty() || expression == QLatin1String("this"))) {
if (!(expression.isEmpty() || expression == QLatin1String("this"))) {
expression = QLatin1String("this");
results = (*m_model->m_typeOfExpression)(utf8Exp, scope);
}
......@@ -1330,7 +1332,7 @@ void CppCompletionAssistProcessor::globalCompletion(CPlusPlus::Scope *currentSco
if (ClassOrNamespace *binding = context.lookupType(scope)) {
for (unsigned i = 0; i < scope->memberCount(); ++i) {
Symbol *member = scope->memberAt(i);
if (! member->name())
if (!member->name())
continue;
if (UsingNamespaceDirective *u = member->asUsingNamespaceDirective()) {
if (ClassOrNamespace *b = binding->lookupType(u->name()))
......@@ -1366,7 +1368,7 @@ void CppCompletionAssistProcessor::globalCompletion(CPlusPlus::Scope *currentSco
for (; currentBinding; currentBinding = currentBinding->parent()) {
const QList<Symbol *> symbols = currentBinding->symbols();
if (! symbols.isEmpty()) {
if (!symbols.isEmpty()) {
if (symbols.first()->isClass())
completeClass(currentBinding);
else
......@@ -1399,7 +1401,7 @@ bool CppCompletionAssistProcessor::completeMember(const QList<CPlusPlus::LookupI
if (binding)
completeClass(binding, /*static lookup = */ true);
return ! m_completions.isEmpty();
return !m_completions.isEmpty();
}
return false;
......@@ -1469,7 +1471,7 @@ bool CppCompletionAssistProcessor::completeScope(const QList<CPlusPlus::LookupIt
}
}
return ! m_completions.isEmpty();
return !m_completions.isEmpty();
}
void CppCompletionAssistProcessor::completeNamespace(CPlusPlus::ClassOrNamespace *b)
......@@ -1478,9 +1480,9 @@ void CppCompletionAssistProcessor::completeNamespace(CPlusPlus::ClassOrNamespace
QList<ClassOrNamespace *> bindingsToVisit;
bindingsToVisit.append(b);
while (! bindingsToVisit.isEmpty()) {
while (!bindingsToVisit.isEmpty()) {
ClassOrNamespace *binding = bindingsToVisit.takeFirst();
if (! binding || bindingsVisited.contains(binding))
if (!binding || bindingsVisited.contains(binding))
continue;
bindingsVisited.insert(binding);
......@@ -1498,9 +1500,9 @@ void CppCompletionAssistProcessor::completeNamespace(CPlusPlus::ClassOrNamespace
scopesToVisit.append(e);
}
while (! scopesToVisit.isEmpty()) {
while (!scopesToVisit.isEmpty()) {
Scope *scope = scopesToVisit.takeFirst();
if (! scope || scopesVisited.contains(scope))
if (!scope || scopesVisited.contains(scope))
continue;
scopesVisited.insert(scope);
......@@ -1519,9 +1521,9 @@ void CppCompletionAssistProcessor::completeClass(CPlusPlus::ClassOrNamespace *b,
QList<ClassOrNamespace *> bindingsToVisit;
bindingsToVisit.append(b);
while (! bindingsToVisit.isEmpty()) {
while (!bindingsToVisit.isEmpty()) {
ClassOrNamespace *binding = bindingsToVisit.takeFirst();
if (! binding || bindingsVisited.contains(binding))
if (!binding || bindingsVisited.contains(binding))
continue;
bindingsVisited.insert(binding);
......@@ -1538,9 +1540,9 @@ void CppCompletionAssistProcessor::completeClass(CPlusPlus::ClassOrNamespace *b,
foreach (Enum *e, binding->unscopedEnums())
scopesToVisit.append(e);
while (! scopesToVisit.isEmpty()) {
while (!scopesToVisit.isEmpty()) {
Scope *scope = scopesToVisit.takeFirst();
if (! scope || scopesVisited.contains(scope))
if (!scope || scopesVisited.contains(scope))
continue;
scopesVisited.insert(scope);
......@@ -1554,7 +1556,7 @@ void CppCompletionAssistProcessor::completeClass(CPlusPlus::ClassOrNamespace *b,
|| member->isQtPropertyDeclaration()
|| member->isQtEnum()) {
continue;
} else if (! staticLookup && (member->isTypedef() ||
} else if (!staticLookup && (member->isTypedef() ||
member->isEnum() ||
member->isClass())) {
continue;
......@@ -1592,11 +1594,11 @@ bool CppCompletionAssistProcessor::completeQtMethod(const QList<CPlusPlus::Looku
continue; // not a pointer or a reference to a pointer.
NamedType *namedTy = ty->asNamedType();
if (! namedTy) // not a class name.
if (!namedTy) // not a class name.
continue;
ClassOrNamespace *b = context.lookupType(namedTy->name(), p.scope());
if (! b)
if (!b)
continue;
QList<ClassOrNamespace *>todo;
......@@ -1617,17 +1619,17 @@ bool CppCompletionAssistProcessor::completeQtMethod(const QList<CPlusPlus::Looku
}
foreach (Scope *scope, scopes) {
if (! scope->isClass())
if (!scope->isClass())
continue;
for (unsigned i = 0; i < scope->memberCount(); ++i) {
Symbol *member = scope->memberAt(i);
Function *fun = member->type()->asFunctionType();
if (! fun)
if (!fun)
continue;
if (wantSignals && ! fun->isSignal())
if (wantSignals && !fun->isSignal())
continue;
else if (! wantSignals && ! fun->isSlot())
else if (!wantSignals && !fun->isSlot())
continue;
unsigned count = fun->argumentCount();
......@@ -1648,7 +1650,7 @@ bool CppCompletionAssistProcessor::completeQtMethod(const QList<CPlusPlus::Looku
signature = QString::fromLatin1(normalized, normalized.size());
if (! signatures.contains(signature)) {
if (!signatures.contains(signature)) {
BasicProposalItem *ci = toCompletionItem(fun);
if (!ci)
break;
......@@ -1666,7 +1668,7 @@ bool CppCompletionAssistProcessor::completeQtMethod(const QList<CPlusPlus::Looku
}
}
return ! m_completions.isEmpty();
return !m_completions.isEmpty();
}
void CppCompletionAssistProcessor::addSnippets()
......@@ -1703,7 +1705,7 @@ void CppCompletionAssistProcessor::addMacros_helper(const CPlusPlus::Snapshot &s
{
Document::Ptr doc = snapshot.document(fileName);
if (! doc || processed->contains(doc->fileName()))
if (!doc || processed->contains(doc->fileName()))
return;
processed->insert(doc->fileName());
......@@ -1714,7 +1716,7 @@ void CppCompletionAssistProcessor::addMacros_helper(const CPlusPlus::Snapshot &s
foreach (const Macro &macro, doc->definedMacros()) {
const QString macroName = QString::fromUtf8(macro.name().constData(), macro.name().length());
if (! macro.isHidden())
if (!macro.isHidden())
definedMacros->insert(macroName);
else
definedMacros->remove(macroName);
......@@ -1733,14 +1735,14 @@ bool CppCompletionAssistProcessor::completeConstructorOrFunction(const QList<CPl
if (Class *klass = asClassOrTemplateClassType(exprTy)) {
const Name *className = klass->name();
if (! className)
if (!className)
continue; // nothing to do for anonymous classes.
for (unsigned i = 0; i < klass->memberCount(); ++i) {
Symbol *member = klass->memberAt(i);
const Name *memberName = member->name();
if (! memberName)
if (!memberName)
continue; // skip anonymous member.
else if (memberName->isQualifiedNameId())
......@@ -1764,10 +1766,13 @@ bool CppCompletionAssistProcessor::completeConstructorOrFunction(const QList<CPl
if (Function *fun = asFunctionOrTemplateFunctionType(ty)) {
if (! fun->name())
if (!fun->name()) {
continue;
else if (! functions.isEmpty() && enclosingNonTemplateScope(functions.first()) != enclosingNonTemplateScope(fun))
} else if (!functions.isEmpty()
&& enclosingNonTemplateScope(functions.first())
!= enclosingNonTemplateScope(fun)) {
continue; // skip fun, it's an hidden declaration.
}
bool newOverload = true;
......@@ -1814,7 +1819,7 @@ bool CppCompletionAssistProcessor::completeConstructorOrFunction(const QList<CPl
// check if function signature autocompletion is appropriate
// Also check if the function name is a destructor name.
bool isDestructor = false;
if (! functions.isEmpty() && ! toolTipOnly) {
if (!functions.isEmpty() && !toolTipOnly) {
// function definitions will only happen in class or namespace scope,
// so get the current location's enclosing scope.
......@@ -1901,7 +1906,7 @@ bool CppCompletionAssistProcessor::completeConstructorOrFunction(const QList<CPl
}
}
if (! functions.empty() && !isDestructor) {
if (!functions.empty() && !isDestructor) {
m_hintProposal = createHintProposal(functions);
return true;
}
......
......@@ -105,7 +105,7 @@ public:
if (Document::Ptr previousDoc = snapshot.document(fileName)) {