xref: /llvm-project/clang/test/CodeGenCXX/apple-kext-guard-variable.cpp (revision 0f1c1be1968076d6f96f8a7bcc4a15cf195ecd97)
1 // RUN: %clang -target x86_64-apple-darwin10 -S -o %t.s -Wno-stdlibcxx-not-found -mkernel -Xclang -verify %s
2 
3 int foo();
test()4 void test() {
5   static int y = 0;
6   static int x = foo(); // expected-error {{this initialization requires a guard variable, which the kernel does not support}}
7 }
8