diff options
author | Bruno Cardoso Lopes <bruno.cardoso@gmail.com> | 2016-12-09 03:30:46 +0000 |
---|---|---|
committer | Bruno Cardoso Lopes <bruno.cardoso@gmail.com> | 2016-12-09 03:30:46 +0000 |
commit | 6e73e3464e96a4e00492c24aa790d36e1adb5702 (patch) | |
tree | a74b3b12892b67b9b309c5f8e54a7d561d84abd0 /test/Headers | |
parent | 732bd78b4ae905a419386752920f3c20c63c9747 (diff) |
[Headers] Add #include_next for tgmath.h on Darwin
Allow darwin to provide additional definitions and implementation
specifc values for tgmath.h on Apple platforms.
rdar://problem/19019845
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@289181 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Headers')
-rw-r--r-- | test/Headers/Inputs/usr/include/tgmath.h | 4 | ||||
-rw-r--r-- | test/Headers/tgmath-darwin.c | 12 |
2 files changed, 16 insertions, 0 deletions
diff --git a/test/Headers/Inputs/usr/include/tgmath.h b/test/Headers/Inputs/usr/include/tgmath.h new file mode 100644 index 0000000000..897962d9e1 --- /dev/null +++ b/test/Headers/Inputs/usr/include/tgmath.h @@ -0,0 +1,4 @@ +#ifndef SYS_TGMATH_H +#define SYS_TGMATH_H + +#endif /* SYS_TGMATH_H */ diff --git a/test/Headers/tgmath-darwin.c b/test/Headers/tgmath-darwin.c new file mode 100644 index 0000000000..b24b6c0c72 --- /dev/null +++ b/test/Headers/tgmath-darwin.c @@ -0,0 +1,12 @@ +// REQUIRES: system-darwin +// RUN: %clang -target x86_64-apple-darwin10 -fsyntax-only -std=c11 -isysroot %S/Inputs %s +#include <tgmath.h> + +// Test the #include_next on tgmath.h works on Darwin. +#ifndef SYS_TGMATH_H + #error "SYS_TGMATH_H not defined" +#endif + +#ifndef __TGMATH_H + #error "__TGMATH_H not defined" +#endif |