From 06ce5352171e153d3e115f57aa736e9c5e340c53 Mon Sep 17 00:00:00 2001 From: Roberto Raggi Date: Fri, 6 Aug 2010 16:41:41 +0200 Subject: [PATCH] Don't mess with the generated symbols. --- src/plugins/cppeditor/cpplocalsymbols.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/plugins/cppeditor/cpplocalsymbols.cpp b/src/plugins/cppeditor/cpplocalsymbols.cpp index e3fbaaee2aa..34122c2bcbf 100644 --- a/src/plugins/cppeditor/cpplocalsymbols.cpp +++ b/src/plugins/cppeditor/cpplocalsymbols.cpp @@ -89,7 +89,7 @@ protected: for (unsigned i = 0; i < scope->symbolCount(); ++i) { if (Symbol *member = scope->symbolAt(i)) { - if (member->isDeclaration() || member->isArgument()) { + if (! member->isGenerated() && (member->isDeclaration() || member->isArgument())) { if (member->name() && member->name()->isNameId()) { const Identifier *id = member->identifier(); unsigned line, column; @@ -107,7 +107,7 @@ protected: const Identifier *id = identifier(simpleName->identifier_token); for (int i = _scopeStack.size() - 1; i != -1; --i) { if (Symbol *member = _scopeStack.at(i)->lookat(id)) { - if (member->sourceLocation() < ast->firstToken() || member->scope()->isPrototypeScope()) { + if (!member->isGenerated() && (member->sourceLocation() < ast->firstToken() || member->scope()->isPrototypeScope())) { unsigned line, column; getTokenStartPosition(simpleName->identifier_token, &line, &column); localUses[member].append(SemanticInfo::Use(line, column, id->size(), SemanticInfo::Use::Local));