From 2b8bac52b8c5690c7a6525c95feefe29bb12178d 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; ~~ ^ ~ git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@41210 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/Sema/unused-expr.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/Sema/unused-expr.c b/test/Sema/unused-expr.c index 667f286f51..245a736f58 100644 --- a/test/Sema/unused-expr.c +++ b/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. -- 2.40.0