Skip to content

Commit 641e1c2

Browse files
committed
Use "_LIBCPP_HAS_MUSL_LIBC" directly
Instead of `#if defined(_LIBCPP_HAS_MUSL_LIBC)`, we can rely on `#if _LIBCPP_HAS_MUSL_LIBC` directly. This should address these failures: # .---command stdout------------ # | /__w/llvm-project/llvm-project/build/frozen-cxx03-headers/libcxx/test-suite-install/include/c++/v1/__locale_dir/support/linux.h:98:6: error: '_LIBCPP_HAS_MUSL_LIBC' is always defined to 1 or 0. [libcpp-internal-ftms,-warnings-as-errors] # | 98 | #if !defined(_LIBCPP_HAS_MUSL_LIBC) # | | ^ # | /__w/llvm-project/llvm-project/build/frozen-cxx03-headers/libcxx/test-suite-install/include/c++/v1/__locale_dir/support/linux.h:108:6: error: '_LIBCPP_HAS_MUSL_LIBC' is always defined to 1 or 0. [libcpp-internal-ftms,-warnings-as-errors] # | 108 | #if !defined(_LIBCPP_HAS_MUSL_LIBC) # | | ^ # `-----------------------------
1 parent 98f7dc5 commit 641e1c2

File tree

1 file changed

+2
-2
lines changed
  • libcxx/include/__locale_dir/support

1 file changed

+2
-2
lines changed

libcxx/include/__locale_dir/support/linux.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ inline _LIBCPP_HIDE_FROM_ABI long double __strtold(const char* __nptr, char** __
9595
}
9696

9797
inline _LIBCPP_HIDE_FROM_ABI long long __strtoll(const char* __nptr, char** __endptr, int __base, __locale_t __loc) {
98-
#if !defined(_LIBCPP_HAS_MUSL_LIBC)
98+
#if !_LIBCPP_HAS_MUSL_LIBC
9999
return ::strtoll_l(__nptr, __endptr, __base, __loc);
100100
#else
101101
(void)__loc;
@@ -105,7 +105,7 @@ inline _LIBCPP_HIDE_FROM_ABI long long __strtoll(const char* __nptr, char** __en
105105

106106
inline _LIBCPP_HIDE_FROM_ABI unsigned long long
107107
__strtoull(const char* __nptr, char** __endptr, int __base, __locale_t __loc) {
108-
#if !defined(_LIBCPP_HAS_MUSL_LIBC)
108+
#if !_LIBCPP_HAS_MUSL_LIBC
109109
return ::strtoull_l(__nptr, __endptr, __base, __loc);
110110
#else
111111
(void)__loc;

0 commit comments

Comments
 (0)