[libcxx-commits] [libcxx] [libc++][test] Avoid some transitive includes in standard headers (PR #145846)

via libcxx-commits libcxx-commits at lists.llvm.org
Wed Jun 25 23:03:05 PDT 2025


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-libcxx

Author: A. Jiang (frederick-vs-ja)

<details>
<summary>Changes</summary>

... for `mangled_names.pass.cpp`

Some builds of this test file seem failing due to not finding `std::errc`. Also removes includes of `<iostream>` and `<string_view>` as they're unused.

---
Full diff: https://github.com/llvm/llvm-project/pull/145846.diff


1 Files Affected:

- (modified) libcxx/test/libcxx/mangled_names.pass.cpp (+3-2) 


``````````diff
diff --git a/libcxx/test/libcxx/mangled_names.pass.cpp b/libcxx/test/libcxx/mangled_names.pass.cpp
index 210c40809781e..6ea8465d870c8 100644
--- a/libcxx/test/libcxx/mangled_names.pass.cpp
+++ b/libcxx/test/libcxx/mangled_names.pass.cpp
@@ -15,11 +15,12 @@
 
 #include <cassert>
 #include <charconv>
-#include <iostream>
+#include <cstddef>
 #include <map>
 #include <typeinfo>
 #include <string>
-#include <string_view>
+#include <system_error>
+#include <utility>
 
 template <class>
 struct mangling {};

``````````

</details>


https://github.com/llvm/llvm-project/pull/145846


More information about the libcxx-commits mailing list