summaryrefslogtreecommitdiff
path: root/src/plugins/cpptools/symbolfinder.cpp
diff options
context:
space:
mode:
authorNikolai Kosjar <nikolai.kosjar@digia.com>2014-05-15 12:00:13 -0400
committerNikolai Kosjar <nikolai.kosjar@digia.com>2014-05-23 14:43:30 +0200
commitacbc4b9f07ee8278ee88857c5be224d15e070ffc (patch)
tree12cd64abf028986905da03a0d7078576e4205e33 /src/plugins/cpptools/symbolfinder.cpp
parent558f62ec71a43c5fac7838f698edd95a26ff892d (diff)
downloadqt-creator-acbc4b9f07ee8278ee88857c5be224d15e070ffc.tar.gz
C++: Get rid of {Name,Type}::isEqualTo()
...since it's superseded by the class Matcher. For consistency, rename FullySpecifiedType::isEqualTo() to match(). Change-Id: I07640f9218d814e0350265de45f05929e5d595a9 Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
Diffstat (limited to 'src/plugins/cpptools/symbolfinder.cpp')
-rw-r--r--src/plugins/cpptools/symbolfinder.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/plugins/cpptools/symbolfinder.cpp b/src/plugins/cpptools/symbolfinder.cpp
index 3f6f192bc2..73ae0d4d82 100644
--- a/src/plugins/cpptools/symbolfinder.cpp
+++ b/src/plugins/cpptools/symbolfinder.cpp
@@ -70,11 +70,11 @@ public:
{
if (_oper) {
if (const Name *name = fun->unqualifiedName()) {
- if (_oper->isEqualTo(name))
+ if (_oper->match(name))
_result.append(fun);
}
} else if (Function *decl = _declaration->type()->asFunctionType()) {
- if (fun->isEqualTo(decl))
+ if (fun->match(decl))
_result.append(fun);
}
@@ -175,7 +175,7 @@ Function *SymbolFinder::findMatchingDefinition(Symbol *declaration,
foreach (Function *fun, viableFunctions) {
if (!(fun->unqualifiedName()
- && fun->unqualifiedName()->isEqualTo(declaration->unqualifiedName()))) {
+ && fun->unqualifiedName()->match(declaration->unqualifiedName()))) {
continue;
}
if (fun->argumentCount() == declarationTy->argumentCount()) {
@@ -187,7 +187,7 @@ Function *SymbolFinder::findMatchingDefinition(Symbol *declaration,
for (; argIt < argc; ++argIt) {
Symbol *arg = fun->argumentAt(argIt);
Symbol *otherArg = declarationTy->argumentAt(argIt);
- if (!arg->type().isEqualTo(otherArg->type()))
+ if (!arg->type().match(otherArg->type()))
break;
}
@@ -252,7 +252,7 @@ static void findDeclarationOfSymbol(Symbol *s,
{
if (Declaration *decl = s->asDeclaration()) {
if (Function *declFunTy = decl->type()->asFunctionType()) {
- if (functionType->isEqualTo(declFunTy))
+ if (functionType->match(declFunTy))
typeMatch->prepend(decl);
else if (functionType->argumentCount() == declFunTy->argumentCount())
argumentCountMatch->prepend(decl);
@@ -316,7 +316,7 @@ void SymbolFinder::findMatchingDeclaration(const LookupContext &context,
if (funcId) {
for (Symbol *s = scope->find(funcId); s; s = s->next()) {
- if (!s->name() || !funcId->isEqualTo(s->identifier()) || !s->type()->isFunctionType())
+ if (!s->name() || !funcId->match(s->identifier()) || !s->type()->isFunctionType())
continue;
findDeclarationOfSymbol(s, functionType, typeMatch, argumentCountMatch, nameMatch);
}