Commit 89132ebc by Dirk Mueller Committed by Dirk Mueller

c-common.c (warn_logical_operator): Fix condition.

2007-03-10  Dirk Mueller  <dmueller@suse.de>

       * c-common.c (warn_logical_operator): Fix condition.

From-SVN: r122800
parent 4cdffe3d
2007-03-10 Dirk Mueller <dmueller@suse.de>
* c-common.c (warn_logical_operator): Fix condition.
2007-03-10 Tobias Schlter <tobi@gcc.gnu.org>
* config/i386/darwin.h (DARWIN_MINVERSION_SPEC): Add missing
......
......@@ -998,8 +998,7 @@ warn_logical_operator (enum tree_code code, tree arg1, tree
&& INTEGRAL_TYPE_P (TREE_TYPE (arg1))
&& !CONSTANT_CLASS_P (arg1)
&& TREE_CODE (arg2) == INTEGER_CST
&& !integer_zerop (arg2)
&& !integer_onep (arg2))
&& !integer_zerop (arg2))
{
warning (OPT_Wlogical_op,
"logical %<%s%> with non-zero constant "
......@@ -1008,7 +1007,6 @@ warn_logical_operator (enum tree_code code, tree arg1, tree
|| (code == TRUTH_AND_EXPR)) ? "&&" : "||");
TREE_NO_WARNING (arg1) = true;
}
break;
default:
break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment