aboutsummaryrefslogtreecommitdiff
path: root/test/Driver/env-include-paths.c
blob: 11876c315b016e5dd4778c3a09e2d6980fc754ee (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// RUN: clang -fsyntax-only -verify -DAS_SOURCE %s &&
// RUN: env CPATH="" clang -fsyntax-only -verify -DAS_SOURCE %s &&
// RUN: env CPATH="xyz:xyz" clang -fsyntax-only -verify -DAS_SOURCE %s &&
// RUN: cd $(dirname %s) &&
// RUN: env CPATH="xyz::xyz" clang -fsyntax-only -verify -DSHOULD_FIND -DAS_SOURCE %s

#ifdef AS_SOURCE
#undef AS_SOURCE

#define AS_INCLUDE

#ifdef SHOULD_FIND
#include <env-include-paths.c>
#endif

#undef AS_INCLUDE

#endif


/* expected-warning {{Hello}} */ #warning "Hello"