[docs] Add LICENSE.txt to the root of the mono-repo
[llvm-project.git] / clang / test / Lexer / pragma-region.c
blobba7e10625b4775c7340c1bb86bc2854da90a35ac
1 /* Test pragma region directive from
2 http://msdn.microsoft.com/en-us/library/b6xkz944(v=vs.80).aspx */
4 // Editor-only pragma, just skipped by compiler.
5 // Syntax:
6 // #pragma region optional name
7 // #pragma endregion optional comment
8 //
9 // RUN: %clang_cc1 -fsyntax-only -verify -Wall -fms-extensions %s
11 #pragma region
12 /* inner space */
13 #pragma endregion
15 #pragma region long name
16 /* inner space */
17 void foo(void){}
18 #pragma endregion long comment
20 void inner(void);
22 __pragma(region) // no sense, but ignored
23 _Pragma("region")// ditto
25 #pragma region2 // expected-warning {{unknown pragma ignored}}
27 #pragma region one
28 #pragma region inner
29 //#pragma endregion inner
31 #pragma endregion end
33 // {{unclosed pragma region}} - region mismatches is not detected yet