add support for local variables with constructors to the symbol database

This commit is contained in:
Robert Reif 2011-07-23 15:12:30 -04:00
parent e332f0c186
commit 5e1fd81ea7
1 changed files with 8 additions and 0 deletions

View File

@ -1828,6 +1828,14 @@ bool Scope::isVariableDeclaration(const Token* tok, const Token*& vartok, const
typetok = localTypeTok;
isArray = true;
}
else if ((isLocal() || type == Scope::eFunction) &&
Token::Match(localVarTok, "%var% (") &&
Token::simpleMatch(localVarTok->next()->link(), ") ;"))
{
vartok = localVarTok;
typetok = localTypeTok;
isArray = false;
}
return NULL != vartok;
}