[libcxx-commits] [libcxx] [libcxx] Fix freestanding build with filesystem disabled on Windows (PR #164602)
via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Oct 28 05:46:53 PDT 2025
Hxnter999 wrote:
`_PathExport` is only used in `path.h`, and its use is already correctly guarded by `_LIBCPP_HAS_LOCALIZATION`. However, its definition is currently only guarded by `_LIBCPP_WIN32API`, even though the implementation depends on localization support (i.e., `__narrow_to_utf8`, `__widen_from_utf8`).
That means we try to build `_PathExport` even when localization is disabled.
Because `_PathExport` is unused without localization, guarding its definition with `_LIBCPP_HAS_LOCALIZATION` should be safe. A similar update is needed in `u8path.h` as well.
https://github.com/llvm/llvm-project/pull/164602
More information about the libcxx-commits
mailing list