[libcxx-commits] [libcxx] [libc++] Narrow the exports for common_type (PR #111681)

Nikolas Klauser via libcxx-commits libcxx-commits at lists.llvm.org
Wed Oct 9 07:10:14 PDT 2024


================
@@ -73,9 +73,9 @@ module std_core [system] {
     module common_reference                           { header "__type_traits/common_reference.h" }
     module common_type {
       header "__type_traits/common_type.h"
-      // We need to export everything from this module because common_type inherits from __builtin_common_type,
-      // which needs to be re-exported.
-      export *
+      // We need to export those because common_type expands to either of those based on __builtin_common_type.
+      export std_core.type_traits.type_identity
+      export std_core.utility_core.empty
----------------
philnik777 wrote:

```suggestion
      // We need to export those because common_type inherits from either of those based on __builtin_common_type.
      export std_core.type_traits.type_identity
      export std_core.utility_core.empty
```

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


More information about the libcxx-commits mailing list