[Bug 55202] Problems parsing global variables (it jumps to one of the places where they are declared with external)
Roberto Raggi
roberto at kdevelop.org
Tue Nov 4 15:53:04 UTC 2003
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
http://bugs.kde.org/show_bug.cgi?id=55202
roberto at kdevelop.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
------- Additional Comments From roberto at kdevelop.org 2003-11-04 15:52 -------
Subject: kdevelop/languages/cpp
CVS commit by raggi:
skip "external" variable declaration
CCMAIL: 55202-done at bugs.kde.org
M +8 -1 store_walker.cpp 1.56
M +1 -0 store_walker.h 1.13
--- kdevelop/languages/cpp/store_walker.cpp #1.55:1.56
@@ -42,4 +42,5 @@ void StoreWalker::parseTranslationUnit(
m_inSlots = false;
m_inSignals = false;
+ m_inStorageSpec = false;
m_anon = 0;
m_imports.clear();
@@ -57,5 +58,8 @@ void StoreWalker::parseDeclaration( Decl
void StoreWalker::parseLinkageSpecification( LinkageSpecificationAST* ast )
{
+ int inStorageSpec = m_inStorageSpec;
+ m_inStorageSpec = true;
TreeParser::parseLinkageSpecification( ast );
+ m_inStorageSpec = inStorageSpec;
}
@@ -348,4 +352,7 @@ void StoreWalker::parseTypeDeclaratation
void StoreWalker::parseDeclaration( GroupAST* funSpec, GroupAST* storageSpec, TypeSpecifierAST* typeSpec, InitDeclaratorAST* decl )
{
+ if( m_inStorageSpec )
+ return;
+
DeclaratorAST* d = decl->declarator();
--- kdevelop/languages/cpp/store_walker.h #1.12:1.13
@@ -72,4 +72,5 @@ private:
bool m_inSignals;
int m_anon;
+ bool m_inStorageSpec;
QValueStack<NamespaceDom> m_currentNamespace;
More information about the KDevelop-devel
mailing list