1 // RUN: %clang_cc1 -triple=x86_64-pc-win32 -verify -fopenmp -x c -std=c99 -fms-extensions -Wno-pragma-pack %s 2 // RUN: %clang_cc1 -triple=x86_64-pc-win32 -verify -fopenmp-simd -x c -std=c99 -fms-extensions -Wno-pragma-pack %s 3 4 // TODO: Issue an eror message as the end is missing 5 // expected-no-diagnostics 6 #pragma omp begin declare variant match(device={kind(cpu)}) also_before(void)7int also_before(void) { 8 return 0; 9 } 10 11 #pragma omp begin declare variant match(device={kind(gpu)}) also_after(void)12int also_after(void) { 13 return 2; 14 } also_before(void)15int also_before(void) { 16 return 2; 17 } 18 #pragma omp end declare variant 19 20 21 #pragma omp begin declare variant match(device={kind(fpga)}) 22 23 This text is never parsed! 24 25 #pragma omp end declare variant 26 27 int also_after(void) { 28 return 0; 29 } 30 test()31int test() { 32 return also_after() + also_before(); 33 } 34