xref: /aosp_15_r20/external/clang/test/Frontend/warning-mapping-5.c (revision 67e74705e28f6214e480b399dd47ea732279e315)
1*67e74705SXin Li // Check that #pragma diagnostic warning overrides -Werror. This matches GCC's
2*67e74705SXin Li // original documentation, but not its earlier implementations.
3*67e74705SXin Li //
4*67e74705SXin Li // RUN: %clang_cc1 -verify -Werror %s
5*67e74705SXin Li 
6*67e74705SXin Li #pragma clang diagnostic warning "-Wsign-compare"
f0(int x,unsigned y)7*67e74705SXin Li int f0(int x, unsigned y) {
8*67e74705SXin Li   return x < y; // expected-warning {{comparison of integers}}
9*67e74705SXin Li }
10