Clang Project

clang_source_code/test/Frontend/warning-mapping-5.c
1// Check that #pragma diagnostic warning overrides -Werror.
2//
3// RUN: %clang_cc1 -verify -Werror %s
4
5#pragma clang diagnostic warning "-Wsign-compare"
6int f0(int x, unsigned y) {
7  return x < y; // expected-warning {{comparison of integers}}
8}
9