-/* RUN: touch %s
- RUN: %clang_cc1 -std=c89 -fsyntax-only -fms-extensions -pedantic -verify %s
- RUN: %clang_cc1 -std=c99 -fsyntax-only -fms-extensions -pedantic -verify %s
- RUN: %clang_cc1 -std=c11 -fsyntax-only -fms-extensions -pedantic -verify %s
- RUN: %clang_cc1 -std=c17 -fsyntax-only -fms-extensions -pedantic -verify %s
- RUN: %clang_cc1 -std=c2x -fsyntax-only -fms-extensions -pedantic -verify %s
+/* RUN: rm -rf %t && mkdir %t
+ RUN: cp %s %t/dr324.c
+
+ Note: this file (dr324.c) must be newer than the file used for the
+ dependency pragma (dep.c), otherwise we get an unrelated "current file is
+ older than dependency" warning. Touch dep.c first to make sure it's
+ always older.
+ RUN: touch %t/dep.c
+ RUN: touch %t/dr324.c
+
+ RUN: %clang_cc1 -std=c89 -fsyntax-only -fms-extensions -pedantic -verify %t/dr324.c
+ RUN: %clang_cc1 -std=c99 -fsyntax-only -fms-extensions -pedantic -verify %t/dr324.c
+ RUN: %clang_cc1 -std=c11 -fsyntax-only -fms-extensions -pedantic -verify %t/dr324.c
+ RUN: %clang_cc1 -std=c17 -fsyntax-only -fms-extensions -pedantic -verify %t/dr324.c
+ RUN: %clang_cc1 -std=c2x -fsyntax-only -fms-extensions -pedantic -verify %t/dr324.c
*/
/* WG14 DR324: yes
/* This test only makes sense on Windows targets, where the backslash is a valid
* path separator.
*/
-#pragma GCC dependency "oops\..\dr0xx.c"
+#pragma GCC dependency "oops\..\dep.c"
#endif
#pragma message("this has a \t tab escape and an invalid \d escape") /* expected-warning {{this has a tab escape and an invalid d escape}}
expected-warning {{unknown escape sequence '\d'}}