1 // Check that Wsystem-headers-in-module shows diagnostics in the named system
2 // module, but not in other system headers or modules.
5 // RUN: split-file %s %t
7 // RUN: %clang_cc1 -fmodules -fimplicit-module-maps -fmodules-cache-path=%t/mcp \
8 // RUN: -isystem %t/sys %t/tu.c -fsyntax-only -Wextra-semi -Wsystem-headers-in-module=sys_mod \
9 // RUN: 2>&1 | FileCheck %s
11 // CHECK-NOT: warning:
12 // CHECK: sys_mod.h:2:7: warning: extra ';'
13 // CHECK-NOT: warning:
15 //--- sys/other_sys_header.h
18 #include "dependent_sys_mod.h"
22 //--- dependent_sys_mod.h
24 //--- module.modulemap
25 module sys_mod
[system
] { header
"sys_mod.h" }
26 module other_sys_mod
[system
] { header
"other_sys_mod.h" }
27 module dependent_sys_mod
[system
] { header
"dependent_sys_mod.h" }
31 #include "other_sys_mod.h"
32 #include "other_sys_header.h"