Merge branch 'master' of https://github.com/danmar/cppcheck
This commit is contained in:
commit
149b0bbd24
|
@ -1216,10 +1216,8 @@ void CheckUnusedVar::checkStructMemberUsage()
|
|||
continue;
|
||||
|
||||
// Try to prevent false positives when struct members are not used directly.
|
||||
if (Token::findmatch(tok, (structname + " *").c_str()))
|
||||
if (Token::findmatch(tok, (structname + " %type%| *").c_str()))
|
||||
structname.clear();
|
||||
else if (Token::findmatch(tok, (structname + " %type% *").c_str()))
|
||||
structname = "";
|
||||
}
|
||||
|
||||
if (tok->str() == "}")
|
||||
|
|
Loading…
Reference in New Issue