xref: /llvm-project/clang/test/Driver/default-includes.cl (revision a9d68a5524dea113cace5983697786599cbdce9a)
1// RUN: %clang %s -Xclang -verify -fsyntax-only
2// RUN: %clang %s -cl-no-stdinc -Xclang -verify -DNOINC -fsyntax-only
3
4#ifndef NOINC
5//expected-no-diagnostics
6#endif
7
8void test() {
9int i = get_global_id(0);
10#ifdef NOINC
11//expected-error@-2{{use of undeclared identifier 'get_global_id'}}
12#endif
13}
14