================
@@ -0,0 +1,14 @@
+// RUN: rm -rf %t
+// RUN: split-file %s %t
+
+// RUN: %clang_cc1 -Wheader-shadowing -Eonly %t/main.c -I %t/include 2>&1 |
FileCheck %s --check-prefix=SHADOWING
+// SHADOWING: {{.*}} warning: multiple candidates for header 'header.h' found;
+
+//--- main.c
+#include "header.h"
----------------
ecnelises wrote:
Better use clang's builtin verify mechanism as other clang tests do.
```suggestion
// RUN: %clang_cc1 -Wheader-shadowing -Eonly %t/main.c -I %t/include -verify
//--- main.c
#include "header.h" // expected-warning-re{{multiple candidates for header
'header.h' found; using the one from '{{[^']+}}', shadowed by
'{{[^']+}}/include'}}
```
https://github.com/llvm/llvm-project/pull/162491
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits