[libc++] Fix incorrect usage of __STDC_HOSTED__
D56913 introduced the _LIBCPP_FREESTANDING macro and guarded its definition by: #ifndef __STDC_HOSTED__ # define _LIBCPP_FREESTANDING #endif However, __STDC_HOSTED__ is defined as 0 in freestanding implementations instead of undefined, which means that _LIBCPP_FREESTANDING would never get defined. This patch corrects the above as: #if __STDC_HOSTED__ == 0 # define _LIBCPP_FREESTANDING #endif Differential Revision: https://reviews.llvm.org/D86055
Loading
Please sign in to comment