forked from qt-creator/qt-creator
Refactored CPlusPlus::Function.
This commit is contained in:
committed by
Oswald Buddenhagen
parent
5f44036424
commit
9aa991d636
@@ -145,7 +145,7 @@ public:
|
||||
newArg->setName(rewrite->rewriteName(arg->name()));
|
||||
newArg->setType(rewrite->rewriteType(arg->type()));
|
||||
|
||||
funTy->arguments()->enterSymbol(newArg);
|
||||
funTy->addMember(newArg);
|
||||
}
|
||||
|
||||
temps.append(funTy);
|
||||
|
||||
@@ -145,7 +145,7 @@ private:
|
||||
|
||||
arg->setType(q->apply(originalArgument->type()));
|
||||
arg->setInitializer(originalArgument->initializer());
|
||||
fun->arguments()->enterSymbol(arg);
|
||||
fun->addMember(arg);
|
||||
}
|
||||
|
||||
_type.setType(fun);
|
||||
|
||||
@@ -282,7 +282,7 @@ QList<LookupItem> LookupContext::lookup(const Name *name, Scope *scope) const
|
||||
|
||||
} else if (scope->isFunctionScope()) {
|
||||
Function *fun = scope->owner()->asFunction();
|
||||
bindings()->lookupInScope(name, fun->arguments(), &candidates, /*templateId = */ 0, /*binding=*/ 0);
|
||||
bindings()->lookupInScope(name, fun->members(), &candidates, /*templateId = */ 0, /*binding=*/ 0);
|
||||
|
||||
for (TemplateParameters *it = fun->templateParameters(); it && candidates.isEmpty(); it = it->previous())
|
||||
bindings()->lookupInScope(name, it->scope(), &candidates, /* templateId = */ 0, /*binding=*/ 0);
|
||||
|
||||
Reference in New Issue
Block a user