[libcxx-commits] [libcxx] a7f8ddc - [libc++] Fixes the Clang modular build.

Mark de Wever via libcxx-commits libcxx-commits at lists.llvm.org
Tue Jan 31 10:20:53 PST 2023


Author: Mark de Wever
Date: 2023-01-31T19:20:46+01:00
New Revision: a7f8ddc4e2e3dac4c123ed8db1704f2753db5722

URL: https://github.com/llvm/llvm-project/commit/a7f8ddc4e2e3dac4c123ed8db1704f2753db5722
DIFF: https://github.com/llvm/llvm-project/commit/a7f8ddc4e2e3dac4c123ed8db1704f2753db5722.diff

LOG: [libc++] Fixes the Clang modular build.

The patch
430b397f6715d4d2f2569716c93fcd6292ace3dc ("[libc++] Granularize <type_traits> includes in <iterator>") missed some exports in the modulemap with became apparent in the reverting commit 12cb1cb3720d.

This fixes the issue by updating the modulemap. Note that the Clang ICE is not fixed by this change.

Reviewed By: #libc, ldionne

Differential Revision: https://reviews.llvm.org/D142690

Added: 
    

Modified: 
    libcxx/include/module.modulemap.in

Removed: 
    


################################################################################
diff  --git a/libcxx/include/module.modulemap.in b/libcxx/include/module.modulemap.in
index 17349f127a19f..95b71863c5f87 100644
--- a/libcxx/include/module.modulemap.in
+++ b/libcxx/include/module.modulemap.in
@@ -758,13 +758,19 @@ module std [system] {
       module derived_from               { private header "__concepts/derived_from.h" }
       module destructible               { private header "__concepts/destructible.h" }
       module 
diff erent_from             { private header "__concepts/
diff erent_from.h" }
-      module equality_comparable        { private header "__concepts/equality_comparable.h" }
+      module equality_comparable {
+        private header "__concepts/equality_comparable.h"
+        export type_traits.common_reference
+      }
       module invocable                  { private header "__concepts/invocable.h" }
       module movable                    { private header "__concepts/movable.h" }
       module predicate                  { private header "__concepts/predicate.h" }
       module regular                    { private header "__concepts/regular.h" }
       module relation                   { private header "__concepts/relation.h" }
-      module same_as                    { private header "__concepts/same_as.h" }
+      module same_as {
+        private header "__concepts/same_as.h"
+        export type_traits.is_same
+      }
       module semiregular                { private header "__concepts/semiregular.h" }
       module swappable                  { private header "__concepts/swappable.h" }
       module totally_ordered            { private header "__concepts/totally_ordered.h" }
@@ -981,7 +987,11 @@ module std [system] {
       module back_insert_iterator  { private header "__iterator/back_insert_iterator.h" }
       module bounded_iter          { private header "__iterator/bounded_iter.h" }
       module common_iterator       { private header "__iterator/common_iterator.h" }
-      module concepts              { private header "__iterator/concepts.h" }
+      module concepts {
+        private header "__iterator/concepts.h"
+        export concepts.equality_comparable
+        export type_traits.common_reference
+      }
       module counted_iterator      { private header "__iterator/counted_iterator.h" }
       module data                  { private header "__iterator/data.h" }
       module default_sentinel      { private header "__iterator/default_sentinel.h" }


        


More information about the libcxx-commits mailing list