summaryrefslogtreecommitdiffstats
path: root/test/CodeGenCXX/static-init-2.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-07-24 01:10:11 +0000
committerChris Lattner <sabre@nondot.org>2010-07-24 01:10:11 +0000
commitb7690b425845b636849f25074d64d30aad646473 (patch)
tree74e751ca9b31dfe691e2292227fe6d67337bf0d7 /test/CodeGenCXX/static-init-2.cpp
parent05b0f4195edf62af76795c92703a1d0c0fa936d9 (diff)
turn down the logical bitwise confusion warning to not warn
when the RHS of the ||/&& is ever 0 or 1. This handles a variety of creative idioms for "true" used in C programs and fixes many false positives at the expense of a few false negatives. This fixes rdar://8230351. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@109314 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGenCXX/static-init-2.cpp')
-rw-r--r--test/CodeGenCXX/static-init-2.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/CodeGenCXX/static-init-2.cpp b/test/CodeGenCXX/static-init-2.cpp
index 7eb4a7d5aa..65ab3bb126 100644
--- a/test/CodeGenCXX/static-init-2.cpp
+++ b/test/CodeGenCXX/static-init-2.cpp
@@ -3,4 +3,4 @@
// Make sure we don't crash generating y; its value is constant, but the
// initializer has side effects, so EmitConstantExpr should fail.
int x();
-int y = x() && 0; // expected-warning {{use of logical && with constant operand}}
+int y = x() && 0;