https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80050
Bug ID: 80050
Summary: gcc/genmatch.c: PVS-Studio: V590
Product: gcc
Version: 7.0.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: other
Assignee: unassigned at gcc dot gnu.org
Reporter: khandeliants at viva64 dot com
Target Milestone: ---
We have found a bug using PVS-Studio tool. PVS-Studio is a static code analyzer
for C, C++ and C#: https://www.viva64.com/en/pvs-studio/
Analyzer warning: V590 Consider inspecting this expression. The expression is
excessive or contains a misprint. genmatch.c 3829
const cpp_token * parser::next ()
{
const cpp_token *token;
do
{
token = cpp_get_token (r);
}
while ( token->type == CPP_PADDING
&& token->type != CPP_EOF); // <=
return token;
}