xref: /llvm-project/clang/test/Preprocessor/whitespace-ms-extensions.c (revision 0e2586779ca6606a3df085f253a31b89b8ad8508)
1 // RUN: %clang_cc1 -E -P %s -o - | FileCheck %s
2 // RUN: %clang_cc1 -E -P -fms-extensions %s -o - | FileCheck %s --check-prefix=MSEXT
3 
4 // -fms-extensions changes __pragma into #pragma
5 // Ensure that there is a newline after the #pragma line.
6 
7 #define MACRO        \
8     text             \
9     __pragma(PRAGMA) \
10     after
11 
12 before MACRO text
13 
14 
15 // CHECK:      before text __pragma(PRAGMA) after text
16 
17 // MSEXT:      before text
18 // MSEXT-NEXT: #pragma PRAGMA
19 // MSEXT-NEXT: after text
20