Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1001)

Unified Diff: test/Sema/atomic-compare.c

Issue 1238843002: Cherry-pick upstream r238083 (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-clang.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « lib/Sema/SemaChecking.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/Sema/atomic-compare.c
diff --git a/test/Sema/atomic-compare.c b/test/Sema/atomic-compare.c
index 2eed091260267d3002d490ac695a3b2bfe5d383b..01eb8200472560fe24e0bffe8736e9cd92628ae1 100644
--- a/test/Sema/atomic-compare.c
+++ b/test/Sema/atomic-compare.c
@@ -19,3 +19,8 @@ void f(_Atomic(int) a, _Atomic(int) b) {
if (!a > b) {} // no warning
if (!a > -1) {} // expected-warning {{comparison of constant -1 with boolean expression is always true}}
}
+
+typedef _Atomic(int) Ty;
+void PR23638(Ty *a) {
+ if (*a == 1) {} // no warning
+}
« no previous file with comments | « lib/Sema/SemaChecking.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698