Skip to content

Commit d89a1eb

Browse files
committed
[Headers][Darwin] Allow #include_next<float.h> to work on Darwin prior to 10.7
This fixes PR31504 and it's a follow up from adding #include_next<float.h> for Darwin in r289018. rdar://problem/29856682 llvm-svn: 309752
1 parent 032d238 commit d89a1eb

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

clang/lib/Headers/float.h

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,15 @@
3333
*/
3434
#if (defined(__APPLE__) || (defined(__MINGW32__) || defined(_MSC_VER))) && \
3535
__STDC_HOSTED__ && __has_include_next(<float.h>)
36+
37+
/* Prior to Apple's 10.7 SDK, float.h SDK header used to apply an extra level
38+
* of #include_next<float.h> to keep Metrowerks compilers happy. Avoid this
39+
* extra indirection.
40+
*/
41+
#ifdef __APPLE__
42+
#define _FLOAT_H_
43+
#endif
44+
3645
# include_next <float.h>
3746

3847
/* Undefine anything that we'll be redefining below. */

0 commit comments

Comments
 (0)