[libc-commits] [libc] [llvm] [libc] Clean up libc_errno implementation, dependencies, and add __errno_location alias (PR #235421)
Pavel Labath via libc-commits
libc-commits at lists.llvm.org
Mon Oct 26 00:29:15 PDT 2026
================
@@ -46,13 +47,20 @@
#if !defined(LIBC_ERRNO_MODE) || LIBC_ERRNO_MODE == LIBC_ERRNO_MODE_DEFAULT
#undef LIBC_ERRNO_MODE
-#if defined(LIBC_FULL_BUILD) || !defined(LIBC_COPT_PUBLIC_PACKAGING)
+#if defined(LIBC_FULL_BUILD) || (!defined(LIBC_COPT_PUBLIC_PACKAGING) && \
+ !defined(LLVM_LIBC_SHARED_LIBC_COMMON_H))
----------------
labath wrote:
Having a different behavior depending on whether some other header was included (first) seems dangerous, as one generally assumes that e.g. clang-formatting the include list is a no-op. What is this trying to do, and is there a way to avoid that?
https://github.com/llvm/llvm-project/pull/235421
More information about the libc-commits
mailing list