From 91b9a4c8c3b04195f023d5d09e9780b4e2f7a90a Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Tue, 21 Aug 2007 01:19:46 +0000 Subject: [PATCH] we now correctly emit: unused-expr.c:8:6: warning: comparison of distinct pointer types ('int volatile *' and 'int *') VP == P; ~~ ^ ~ llvm-svn: 41210 --- clang/test/Sema/unused-expr.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/clang/test/Sema/unused-expr.c b/clang/test/Sema/unused-expr.c index 667f286f510b..245a736f58e9 100644 --- a/clang/test/Sema/unused-expr.c +++ b/clang/test/Sema/unused-expr.c @@ -5,7 +5,8 @@ int foo(int X, int Y); void bar(volatile int *VP, int *P, int A, _Complex double C, volatile _Complex double VC) { - VP == P; // expected-warning {{expression result unused}} + VP == P; // expected-warning {{expression result unused}} \ + expected-warning {{comparison}} (void)A; // expected-warning {{expression result unused}} (void)foo(1,2); // no warning.