diff --git a/libcxx/docs/Contributing.rst b/libcxx/docs/Contributing.rst --- a/libcxx/docs/Contributing.rst +++ b/libcxx/docs/Contributing.rst @@ -47,13 +47,30 @@ - Did you add all new named declarations to the ``std`` module? - If you added a header: - - Did you add it to ``include/module.modulemap.in``? - Did you add it to ``include/CMakeLists.txt``? - If it's a public header, did you update ``utils/libcxx/test/header_information.py``? - Did you add the relevant feature test macro(s) for your feature? Did you update the ``generate_feature_test_macro_components.py`` script with it? - Did you run the ``libcxx-generate-files`` target and verify its output? +clang modules +============= + +The clang module map is put together from ``include/module.modulemap.in`` and ``include/internal_module_attributes.json.in`` +by ``include/generate_module_map.py``. + +- Public headers need to be added to ``include/module.modulemap.in``. +- Private headers will be automatically added to the generated module map. +- Private module attributes need to be added to ``include/internal_module_attributes.json.in``. + Most private headers do not need any module attributes. +- ``include/generate_module_map.py`` may need to be modified in the following situations. + - ``validate_exports`` needs to be updated if module naming conventions change. + - ``write_libcxx_includes`` needs to be updated when the subdirectories and files that need to be ignored are updated. + - ``build_include_tree`` needs to be updated when new C++ versions are added. + - ``build_include_tree`` needs to be updated when new macros control what gets included. So far there is one set of + macros that maximizes the includes. If that becomes false, then the script will need to be updated to run different + combinations of macros to catch every possible include. + The review process ================== diff --git a/libcxx/include/CMakeLists.txt b/libcxx/include/CMakeLists.txt --- a/libcxx/include/CMakeLists.txt +++ b/libcxx/include/CMakeLists.txt @@ -1013,10 +1013,8 @@ endforeach() configure_file("__config_site.in" "${LIBCXX_GENERATED_INCLUDE_TARGET_DIR}/__config_site" @ONLY) -configure_file("module.modulemap.in" "${LIBCXX_GENERATED_INCLUDE_DIR}/module.modulemap" @ONLY) -set(_all_includes "${LIBCXX_GENERATED_INCLUDE_TARGET_DIR}/__config_site" - "${LIBCXX_GENERATED_INCLUDE_DIR}/module.modulemap") +set(_all_includes "${LIBCXX_GENERATED_INCLUDE_TARGET_DIR}/__config_site") foreach(f ${files}) set(src "${CMAKE_CURRENT_SOURCE_DIR}/${f}") set(dst "${LIBCXX_GENERATED_INCLUDE_DIR}/${f}") @@ -1027,6 +1025,50 @@ list(APPEND _all_includes "${dst}") endforeach() +check_cxx_compiler_flag(-cxx-isystem CXX_SUPPORTS_CXX_ISYSTEM_FLAG) +check_cxx_compiler_flag(-fshow-skipped-includes CXX_SUPPORTS_FSHOW_SKIPPED_INCLUDES_FLAG) +if (CXX_SUPPORTS_CXX_ISYSTEM_FLAG AND CXX_SUPPORTS_FSHOW_SKIPPED_INCLUDES_FLAG AND CXX_SUPPORTS_NOSTDINCXX_FLAG) + set(LIBCXX_INTERMEDIATES_DIR "${LLVM_BINARY_DIR}/intermediates") + configure_file(module.modulemap.in "${LIBCXX_INTERMEDIATES_DIR}/module.modulemap" @ONLY) + configure_file(internal_module_attributes.json.in "${LIBCXX_INTERMEDIATES_DIR}/internal_module_attributes.json" @ONLY) + + if (LIBCXX_GENERATED_INCLUDE_DIR STREQUAL LIBCXX_GENERATED_INCLUDE_TARGET_DIR) + set(libcxx_include_target_directory "") + else() + set(libcxx_include_target_directory --libcxx-include-target-directory "${LIBCXX_GENERATED_INCLUDE_TARGET_DIR}") + endif() + + if (DEFINED CMAKE_CXX_COMPILER_TARGET) + set(compiler_target --target ${CMAKE_CXX_COMPILER_TARGET}) + elseif (DEFINED LLVM_DEFAULT_TARGET_TRIPLE) + set(compiler_target --target ${LLVM_DEFAULT_TARGET_TRIPLE}) + else() + set(compiler_target "") + endif() + + if (DEFINED CMAKE_OSX_SYSROOT) + set(isysroot --isysroot ${CMAKE_OSX_SYSROOT}) + else() + set(isysroot "") + endif() + + add_custom_command(OUTPUT "${LIBCXX_GENERATED_INCLUDE_DIR}/module.modulemap" + DEPENDS "${CMAKE_CURRENT_SOURCE_DIR}/generate_module_map.py" + "${LIBCXX_INTERMEDIATES_DIR}/module.modulemap" + "${LIBCXX_INTERMEDIATES_DIR}/internal_module_attributes.json" + ${_all_includes} + COMMAND "${Python3_EXECUTABLE}" "${CMAKE_CURRENT_SOURCE_DIR}/generate_module_map.py" + --libcxx-include-directory "${LIBCXX_GENERATED_INCLUDE_DIR}" + ${libcxx_include_target_directory} + --intermediates-directory "${LIBCXX_INTERMEDIATES_DIR}" + --cxx-compiler "${CMAKE_CXX_COMPILER}" + ${compiler_target} + ${isysroot} + COMMENT "Generating clang module map module.modulemap") + + list(APPEND _all_includes "${LIBCXX_GENERATED_INCLUDE_DIR}/module.modulemap") +endif() + add_custom_target(generate-cxx-headers ALL DEPENDS ${_all_includes}) add_library(cxx-headers INTERFACE) @@ -1052,10 +1094,12 @@ COMPONENT cxx-headers) # Install the generated modulemap file to the generic include dir. - install(FILES "${LIBCXX_GENERATED_INCLUDE_DIR}/module.modulemap" - DESTINATION "${LIBCXX_INSTALL_INCLUDE_DIR}" - PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ - COMPONENT cxx-headers) + if (EXISTS "${LIBCXX_GENERATED_INCLUDE_DIR}/module.modulemap") + install(FILES "${LIBCXX_GENERATED_INCLUDE_DIR}/module.modulemap" + DESTINATION "${LIBCXX_INSTALL_INCLUDE_DIR}" + PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ + COMPONENT cxx-headers) + endif() if (NOT CMAKE_CONFIGURATION_TYPES) add_custom_target(install-cxx-headers diff --git a/libcxx/include/generate_module_map.py b/libcxx/include/generate_module_map.py new file mode 100644 --- /dev/null +++ b/libcxx/include/generate_module_map.py @@ -0,0 +1,974 @@ +# ===----------------------------------------------------------------------===## +# +# Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +# See https://llvm.org/LICENSE.txt for license information. +# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +# +# ===----------------------------------------------------------------------===## + +import argparse +import json +import operator +import os +import pathlib +import posixpath +import re +import subprocess +import typing + + +# The private libc++ detail headers are interdependent such that putting all +# of the e.g. __algorithm/*.h headers in a single module will result in module +# cycles with other libc++ modules. This script figures out how to group the +# private headers in the minimum number of modules per directory using the +# following system. +# 1. Run the preprocessor to get the includes of every libc++ header. +# 2. Build an include tree from the preprocessor output. +# 3. For each private header, collect the list of headers that transitively +# include it, and it transitively includes. +# 4. Convert the private headers and their transitive includes into modules. +# 5 Merge modules that are in the same directory and don't create a module +# cycle. Modules can be merged if the includers of each module are not in +# the includees of the other module. In other words, if they're at the same +# level of the module tree. +# This is quite similar to a disjoint-set/union-find forest, and could possibly +# be reimplemented as such. +def main() -> None: + parser = argparse.ArgumentParser() + parser.add_argument("--libcxx-include-directory", required=True) + parser.add_argument("--libcxx-include-target-directory") + parser.add_argument("--intermediates-directory", required=True) + parser.add_argument("--cxx-compiler", required=True) + parser.add_argument("--target") + parser.add_argument("--isysroot") + args = parser.parse_args() + + with open( + os.path.join(args.intermediates_directory, "internal_module_attributes.json") + ) as module_attributes_file: + module_attributes = json.load(module_attributes_file) + validate_exports( + args.libcxx_include_directory, + args.libcxx_include_target_directory, + args.intermediates_directory, + module_attributes, + ) + libcxx_includes_path = os.path.join( + args.intermediates_directory, "libcxx_includes.cpp" + ) + with open(libcxx_includes_path, "w") as libcxx_includes_file: + write_libcxx_includes(args.libcxx_include_directory, libcxx_includes_file) + include_tree = build_include_tree( + args.cxx_compiler, + args.target, + args.isysroot, + args.libcxx_include_directory, + args.libcxx_include_target_directory, + libcxx_includes_path, + module_attributes, + ) + private_headers_by_directory = collect_transitive_includes(include_tree) + modules_by_directory = build_modules(private_headers_by_directory) + write_module_map( + modules_by_directory, + args.libcxx_include_directory, + args.intermediates_directory, + module_attributes, + ) + sanity_check_module_map(args.libcxx_include_directory, include_tree) + + +def validate_exports( + libcxx_include_directory: str, + libcxx_include_target_directory: str, + intermediates_directory: str, + module_attributes: typing.Dict[str, dict], +) -> None: + # Behavior is undefined if a module exports something that none of its headers include. + def export_is_valid_in_header(export: str, header: str) -> bool: + def find_include_in_header( + include_regular_expression: re.Pattern, header_file: typing.TextIO + ) -> bool: + for line in header_file: + if include_regular_expression.search(line): + return True + return False + + # Exports can be either a placeholder for a private header or a real module + # name. It's assumed that module names can be mapped to header names by + # stripping std_ and converting a trailing _h to .h. + include = export + if include.startswith("std_"): + include = include[len("std_") :] + if include.endswith("_h"): + include = include[: -len("_h")] + ".h" + include_regular_expression = re.compile( + r"# *include <" + re.escape(include) + r">" + ) + + try: + with open(os.path.join(libcxx_include_directory, header)) as header_file: + return find_include_in_header(include_regular_expression, header_file) + except FileNotFoundError: + if libcxx_include_target_directory != libcxx_include_directory: + with open( + os.path.join(libcxx_include_target_directory, header) + ) as header_file: + return find_include_in_header( + include_regular_expression, header_file + ) + else: + raise + + invalid_exports = {} + + # Go through the module map lines in reverse order. This makes some simplifying + # assumptions. + # 1. `export` comes after all the `header`s in the module. + # 2. There's only 1 `header` per module, or at least the last listed header in the + # module is the one that includes the export. + with open(os.path.join(intermediates_directory, "module.modulemap")) as module_map: + module_map_lines = list(reversed(list(module_map))) + + # Exports can be of three forms. + # 1. A real module like `export std_cstddef`. + # 2. A placeholder for a private file like `export "__fwd/span.h"`. + # 3. A wildcard `export *`, which doesn't need to be validated. + specific_export_regular_expression = re.compile(r'export "?([\w./]+)') + header_regular_expression = re.compile(r'header "(.*)"') + for line_index, module_map_line in enumerate(module_map_lines): + export_match = specific_export_regular_expression.search(module_map_line) + if export_match: + found_header_match = False + for remaining_line in module_map_lines[line_index:]: + header_match = header_regular_expression.search(remaining_line) + if header_match: + found_header_match = True + if not export_is_valid_in_header(export_match[1], header_match[1]): + invalid_exports.setdefault(header_match[1], []).append( + export_match[1] + ) + break + assert found_header_match, f"Failed to find header for {export_match[1]}" + + # Go through the module attributes. (Some of the entries are directories, but + # those don't have exports.) + for header, header_module_attributes in module_attributes.items(): + for export in header_module_attributes.get("exports", []): + if (export != "*") and not export_is_valid_in_header(export, header): + invalid_exports.setdefault(header, []).append(export) + + if invalid_exports: + for header, exports in invalid_exports.items(): + print("Module for <", header, "> has invalid exports", sep="") + for export in exports: + print(" ", export) + print() + exit(1) + + +def write_libcxx_includes( + libcxx_include_directory: str, libcxx_includes_file: typing.TextIO +) -> None: + for directory, subdirectorynames, filenames in os.walk(libcxx_include_directory): + if directory == libcxx_include_directory: + include_root = "" + # The ext, and __support headers are not included in the module. Not all of + # the __pstl headers compile, so exclude that directory too, even though some + # of the headers will be pulled in transitively and modularized. + subdirectorynames.remove("ext") + subdirectorynames.remove("__pstl") + subdirectorynames.remove("__support") + else: + include_root = pathlib.PurePath( + os.path.relpath(directory, libcxx_include_directory) + ).as_posix() + + subdirectorynames.sort() + for filename in sorted(filenames): + # The __pstl and cxxabi headers are not included in the module. + if (directory == libcxx_include_directory) and ( + filename.startswith("__pstl_") or ("cxxabi" in filename) + ): + continue + + extension = os.path.splitext(filename)[1] + if ( + (not extension) + or (extension == ".h") + or (extension == ".hh") + or (extension == ".hp") + or (extension == ".hpp") + or (extension == ".hxx") + or (extension == ".h++") + or (extension == ".ipp") + ): + # Only extension-less and .h headers should be present, but allow for any C++ header file. + libcxx_includes_file.write("#include <") + libcxx_includes_file.write(posixpath.join(include_root, filename)) + libcxx_includes_file.write(">\n") + + +def build_include_tree( + cxx_compiler: str, + target: typing.Optional[str], + isysroot: typing.Optional[str], + libcxx_include_directory: str, + libcxx_include_target_directory: typing.Optional[str], + libcxx_includes_path: str, + module_attributes: typing.Dict[str, dict], +) -> typing.Iterable["Header"]: + headers = {} # header objects keyed by path + # includes vary by standard, so all standards need to be run, and the includes unioned. + for standard in ["c++98", "c++11", "c++14", "c++17", "c++20", "c++2b"]: + cxx_command = [cxx_compiler] + if target: + cxx_command += ["-target", target] + if isysroot: + cxx_command += ["-isysroot", isysroot] + cxx_command += ["-E", "-H", "-fshow-skipped-includes"] + cxx_command.append("-std=" + standard) + cxx_command.append("-D_LIBCPP_ENABLE_EXPERIMENTAL") + if standard != "c++98": + cxx_command.append("-D_LIBCPP_DEBUG_RANDOMIZE_UNSPECIFIED_STABILITY") + cxx_command.append("-nostdinc++") + cxx_command += ["-cxx-isystem", libcxx_include_directory] + if libcxx_include_target_directory: + cxx_command += ["-cxx-isystem", libcxx_include_target_directory] + cxx_command.append("-w") + cxx_command.append(libcxx_includes_path) + + # Don't require the command to succeed, some of the headers have #error directives if features + # are disabled like threads, locales, wide characters, etc. Those headers just don't show any + # includes which is fine. + includes = subprocess.run( + cxx_command, + stdout=subprocess.DEVNULL, + stderr=subprocess.PIPE, + text=True, + ).stderr + + # Consider 'a' that includes 'b' and 'c', 'b' that includes 'c', and 'c' that includes + # nothing. All three headers have header guards. For an input file that includes all three, + # -H -fshow-skipped-includes will look like this. + # . /a + # .. /b + # ... /c + # .. /c + # . /b + # . /c + # The last three lines are skipped includes - a's include of c is skipped because c has already + # been seen via b, and same with the input file's includes of b and c that have already been seen + # via a and b. Skipped includes do not re-list any of their includes, which is why there isn't a + # ".. /c" under ". /b". The first time a header is seen, it will show all of its direct includes + # and potentially some of its transitive includes. Headers without header guards are not skipped, + # and can have different includes depending on the context. + header_stack = [] # list of tuples (level, path) + for line in includes.splitlines(): + if not line.startswith("."): + continue + + dots, include = line.split(" ", maxsplit=1) + level = len(dots) + current_header = headers.get(include) + if not current_header: + current_header = Header( + include, libcxx_include_directory, module_attributes + ) + headers[include] = current_header + + while header_stack and (level <= header_stack[-1][0]): + del header_stack[-1] + + if header_stack: + parent_header = header_stack[-1][1] + parent_header.included_headers.add(current_header) + current_header.including_headers.add(parent_header) + + header_stack.append((level, current_header)) + return headers.values() + + +def collect_transitive_includes( + include_tree: typing.Iterable["Header"], +) -> typing.Dict[str, typing.List["Header"]]: + def collect_transitive_includes_for_header( + header: "Header", + include_attribute: str, + transitive_include_attribute: str, + should_detect_cycles: bool, + ) -> typing.Set[typing.Tuple["Header"]]: + transitive_includes = getattr(header, transitive_include_attribute) + + # includes_to_follow is a list of sets of headers. It starts out as the + # includes from the header being analyzed. One of the includes is taken + # from the last set, and its includes are added to the end of the list. + # Another include is selected from the new last set, and so on until the + # include path hits the end, or a cycle is detected. After that, the + # include path removes its last include, and a sibling include from the + # last set is selected. When there are no more siblings, the include path + # goes up a level until eventually there are no more includes to process. + includes = getattr(header, include_attribute) + includes_to_follow = [includes.copy()] if includes else [] + include_path = [header] + + seen_headers = {header} + cycles = set() + while includes_to_follow: + selected_header = includes_to_follow[-1].pop() + transitive_includes.add(selected_header) + + include_path.append(selected_header) + selected_header_includes = getattr(selected_header, include_attribute) + + if should_detect_cycles: + cycles |= detect_cycles(include_path, selected_header_includes) + + selected_header_includes_to_follow = selected_header_includes - seen_headers + if selected_header_includes_to_follow: + includes_to_follow.append(selected_header_includes_to_follow) + else: + # Hit the end of the include path, peel back a level. + del include_path[-1] + + # Peel back the completed levels. + while includes_to_follow and not includes_to_follow[-1]: + del includes_to_follow[-1] + del include_path[-1] + + seen_headers.add(selected_header) + + return cycles + + private_headers_by_directory = {} + cycles = set() + for header in include_tree: + if not header.is_private_libcxx_header: + continue + + # The same cycles should be returned as the graph is traversed up and down. Just collect them + # from the included headers since that's the more intuitive direction ("a includes b includes c + # includes a" rather than "c is included by b is included by a is included by c"). + collect_transitive_includes_for_header( + header, + "including_headers", + "transitive_including_headers", + should_detect_cycles=False, + ) + cycles |= collect_transitive_includes_for_header( + header, + "included_headers", + "transitive_included_headers", + should_detect_cycles=True, + ) + private_headers_by_directory.setdefault(header.module_directory, []).append( + header + ) + + if cycles: + print( + "Include cycles detected across libc++ modules, these must be broken before modules can be made for the libc++ private headers\n" + ) + for cycle in sorted(cycles): + for header in cycle: + print(header.path) + print() + exit(1) + + return private_headers_by_directory + + +def detect_cycles( + include_path: typing.List["Header"], next_includes: typing.Set["Header"] +) -> typing.Set[typing.Tuple["Header"]]: + cycles = set() + for index, include_header in enumerate(include_path): + if include_header in next_includes: + # Include cycles are only a problem if they cross module boundaries. + # If the cycle just consists of non-libc++ headers, then presumably + # those are all in the same module and it's fine. + # + # If only one libc++ header is involved, then it's unclear if the + # cycle needs to be broken in libc++ or externally. Don't report + # that cycle either, if the non-libc++ headers are in a + # [no_undeclared_includes] module, then that will break the cycle. + # Otherwise, the module cycle should be caught in the modules_include + # unit test and a strategy can be devised from there. + # + # A cycle involving only private headers in the same directory isn't + # technically a problem if those headers could be grouped into the + # same module. However, figuring out if the headers can be grouped is + # tricky at this point, and there aren't currently any such cycles. + # For now, don't allow that situation. + libcxx_header_count = 0 + cycle = include_path[index:] + for cycle_header in cycle: + if cycle_header.is_libcxx_header: + libcxx_header_count += 1 + + if libcxx_header_count >= 2: + # The include cycle could potentially be entered at any point and + # thus get double reported, i.e. as a -> b -> a and b -> a -> b. + # Rotate the cycle so that the smallest item is at the end points. + # For the above cycle, assume that include_path = cycle = [b, a] + # and b is in next_includes. Report (a, b, a) as the cycle by + # starting at a and going to the end, then going from the start + # back to and including a. + starting_point = cycle.index(min(cycle)) + cycles.add( + (*cycle[starting_point:], *cycle[: (starting_point + 1)]) + ) + break + return cycles + + +def build_modules( + private_headers_by_directory: typing.Dict[str, typing.List["Header"]] +) -> typing.Dict[str, "Module"]: + # Build the initial set of modules. + modules_by_directory, all_modules = group_headers_into_modules( + private_headers_by_directory + ) + + # The modules essentially constitute a module tree parallel to the include tree*. Enumerate + # the modules and merge them where it doesn't create a cycle. Module a and b can be merged + # if none of b's including modules are included by a, and if none of a's including modules + # are included by b. Multiple passes are required, consider a -> c -> b. On the first pass, + # a and b can't be merged because that would make a cycle ab -> c -> ab. However a and c + # can be merged: ac -> b. On the second pass, ac can merge with b. Keep looping until no + # more merges can be made. + # + # * "essentially" because only the private libc++ headers are put into modules, the remaining + # headers stay as headers and are optimistically treated like modules. The libc++ public headers + # are each in their own standalone module, except for the experimental headers which are all + # together in a single module. It's assumed that the experimental module sits strictly on top + # of all of the other libc++ modules. That is, nothing includes experimental headers except other + # experimental headers, they'll never show up in any module's included headers, and so they won't + # effectively matter for grouping. The non-libc++ headers are optimistically assumed to be in + # individual modules. If that isn't the case, then it's possible that they can cause module cycles. + # The modules_include unit test will catch those, and if there are any then a strategy can be + # found to solve the cycle. + did_merge = True + while did_merge: + did_merge, modules_by_directory = merge_modules( + modules_by_directory, all_modules + ) + + # The module lists in modules_for_directory are sorted so that the headers roughly come out in + # alphabetical order. If headers are grouped into modules acf, be, d, then the modules will be + # in that order, except reversed for ease of list enumeration. Reverse the lists so that they're + # in the right order before returning them. The headers in each module are unsorted, e.g. the + # first module might actually be afc, sort those so that they're in the right order too. + for directory, modules_for_directory in modules_by_directory.items(): + for module in modules_for_directory: + module.headers.sort(key=operator.attrgetter("submodule_name")) + modules_for_directory.reverse() + return modules_by_directory + + +def group_headers_into_modules( + private_headers_by_directory: typing.Dict[str, typing.List["Header"]] +) -> typing.Tuple[typing.Dict[str, "Module"], typing.List["Module"]]: + # Headers are safe to group if their including and included headers match, modulo each other. + # In other words, if a and b's transitive includes match except that a includes b and b is + # included by a, then they can be grouped. It's tempting to try to more aggressively group + # headers that look like they're at the same level in the include tree, however that can + # create module cycles. e.g. a1 -> b1, b2 -> a2. None of a2's including headers are included + # by a1 and vice versa, and same with b2 and b1. However, if the a's and b's are both grouped + # into modules, then a1a2 -> b1b2 -> a1a2 and it's a module cycle. Start simple with the + # initial modules and only do the failsafe grouping. + def has_differing_transitive_includes( + module: "Module", header: "Header", include_attribute: str + ) -> bool: + differing_transitive_includes = getattr(module, include_attribute) ^ getattr( + header, include_attribute + ) + differing_transitive_includes.discard(header) + differing_transitive_includes.difference_update(module.headers) + return bool(differing_transitive_includes) + + modules = [] + modules_by_directory = {} + modules_by_header = {} + for directory, headers in private_headers_by_directory.items(): + # Visit the headers in alphabetical order. Reverse the headers and then enumerate + # them in reverse so that the consumed headers can be removed while enumerating. + sorted_headers = sorted( + headers, key=operator.attrgetter("submodule_name"), reverse=True + ) + modules_for_directory = modules_by_directory.setdefault(directory, []) + while sorted_headers: + header = sorted_headers.pop() + module = Module(header) + modules_by_header[header] = module + index = -1 + for candidate_header in reversed(sorted_headers): + if ( + not has_differing_transitive_includes( + module, candidate_header, "transitive_including_headers" + ) + ) and ( + not has_differing_transitive_includes( + module, candidate_header, "transitive_included_headers" + ) + ): + module.headers.append(candidate_header) + module.transitive_including_headers.discard(candidate_header) + module.transitive_included_headers.discard(candidate_header) + + modules_by_header[candidate_header] = module + del sorted_headers[index] + else: + index -= 1 + modules.append(module) + # Set up the modules for directory in reverse order so that they can + # be enumerated and trimmed in reverse order below in similar fashion + # to the headers here. + modules_for_directory.insert(0, module) + + # Replace the private headers in the modules' including/included headers with their new modules. + def replace_headers_with_modules( + module: "Module", headers_attribute: str, modules_attribute: str + ) -> None: + transitive_headers = getattr(module, headers_attribute) + transitive_modules = getattr(module, modules_attribute) + headers_with_modules = set() + for header in transitive_headers: + module_for_header = modules_by_header.get(header) + if module_for_header: + headers_with_modules.add(header) + transitive_modules.add(module_for_header) + transitive_headers -= headers_with_modules + + for module in modules: + replace_headers_with_modules( + module, "transitive_including_headers", "transitive_including_modules" + ) + replace_headers_with_modules( + module, "transitive_included_headers", "transitive_included_modules" + ) + + return modules_by_directory, modules + + +def merge_modules( + modules_by_directory: typing.Dict[str, "Module"], all_modules: typing.List["Module"] +) -> typing.Tuple[bool, typing.Dict[str, "Module"]]: + def merge_transitive_module_includes( + surviving_module: "Module", + module_being_merged: "Module", + transitive_modules_attribute: str, + ) -> None: + transitive_modules = getattr(surviving_module, transitive_modules_attribute) + transitive_modules |= getattr(module_being_merged, transitive_modules_attribute) + # If the modules being merged included each other, remove those references. + transitive_modules.discard(surviving_module) + transitive_modules.discard(module_being_merged) + + def update_transitive_module_includes( + module: "Module", + surviving_module: "Module", + module_being_merged: "Module", + transitive_modules_attribute: str, + ) -> None: + transitive_modules = getattr(module, transitive_modules_attribute) + if (surviving_module in transitive_modules) and ( + module_being_merged not in transitive_modules + ): + transitive_modules |= getattr( + module_being_merged, transitive_modules_attribute + ) + if module_being_merged in transitive_modules: + if surviving_module not in transitive_modules: + transitive_modules.add(surviving_module) + transitive_modules |= getattr( + surviving_module, transitive_modules_attribute + ) + transitive_modules.remove(module_being_merged) + + # Use the same double-reversed strategy as was used to enumerate the headers. + did_merge = False + merged_modules_by_directory = {} + for directory, modules_for_directory in modules_by_directory.items(): + merged_modules_for_directory = merged_modules_by_directory.setdefault( + directory, [] + ) + while modules_for_directory: + module = modules_for_directory.pop() + index = -1 + for candidate_module in reversed(modules_for_directory): + # Modules can be merged as long as it won't create a module cycle. Module a and b can be merged + # if none of b's including modules are included by a, and if none of a's including modules are + # included by b. The headers that don't have known modules are treated as if they're in their + # own standalone module, see the comment in build_modules. + if ( + candidate_module.transitive_including_headers.isdisjoint( + module.transitive_included_headers + ) + and module.transitive_including_headers.isdisjoint( + candidate_module.transitive_included_headers + ) + and candidate_module.transitive_including_modules.isdisjoint( + module.transitive_included_modules + ) + and module.transitive_including_modules.isdisjoint( + candidate_module.transitive_included_modules + ) + ): + # Update the rest of the modules with the merge. This needs to happen after every + # merge so that subsequent merge attempts can correctly identify cycles. For + # a1 -> b1, b2 -> a2, a1 and a2 will be merged into a1a2. b1 and b2 need to be + # updated to a1a2 -> b1, b2 -> a1a2 so that they don't get merged and create a cycle. + # Another scenario is a -> b, c -> d, e -> a. If d and e merge, c needs to not only + # replace d with de, but it also has to add all of e's transitive includes, i.e. a, + # so that c doesn't later merge with b and cause a cycle a -> bc -> de -> a. + all_modules.remove(candidate_module) + for module_to_update in all_modules: + update_transitive_module_includes( + module_to_update, + module, + candidate_module, + "transitive_including_modules", + ) + update_transitive_module_includes( + module_to_update, + module, + candidate_module, + "transitive_included_modules", + ) + + # Merge the candidate module. + module.headers += candidate_module.headers + module.transitive_including_headers |= ( + candidate_module.transitive_including_headers + ) + module.transitive_included_headers |= ( + candidate_module.transitive_included_headers + ) + merge_transitive_module_includes( + module, candidate_module, "transitive_including_modules" + ) + merge_transitive_module_includes( + module, candidate_module, "transitive_included_modules" + ) + + did_merge = True + del modules_for_directory[index] + else: + index -= 1 + merged_modules_for_directory.insert(0, module) + + return did_merge, merged_modules_by_directory + + +def write_module_map( + modules_by_directory: typing.Dict[str, typing.List["Module"]], + libcxx_include_directory: str, + intermediates_directory: str, + module_attributes: typing.Dict[str, dict], +) -> None: + # Figure out all of the module names to resolve the exports from the module attributes. + sorted_directories_and_modules = sorted( + modules_by_directory.items(), key=operator.itemgetter(0) + ) + libcxx_include_directory_as_posix = pathlib.PurePath( + libcxx_include_directory + ).as_posix() + module_names_by_relative_include_path = {} + for directory, modules in sorted_directories_and_modules: + module_name_base = "std_private" + if directory != libcxx_include_directory: + directory_name = posixpath.relpath( + directory, libcxx_include_directory_as_posix + ) + # Some directories are suffixed with '_dir' to not collide with header names. e.g. 's + # private headers are in __locale_dir because there's already a __locale file. Drop the '_dir' + # from the module name. + if directory_name.endswith("_dir"): + directory_name = directory_name[: -len("_dir")] + module_name_base += "_" + directory_name.lstrip("_").replace( + posixpath.sep, "_" + ) + + module_number = 1 + use_module_number = len(modules) > 1 + + for module in modules: + module_name = module_name_base + if use_module_number: + module_name += "_" + str(module_number) + module.name = module_name + + for header in module.headers: + module_names_by_relative_include_path[ + header.libcxx_include_relative_path + ] = (module_name + "." + header.submodule_name) + + module_number += 1 + + with open( + os.path.join(libcxx_include_directory, "module.modulemap"), "w" + ) as destination_module_map: + # Append the dynamically generated private modules to the statically defined public modules in the + # intermediates directory. Public modules in the static module map export private modules using the + # header name in quotes as a placeholder. Replace that with the actual private module name. + export_regular_expression = re.compile(r'export ("(.*)")') + with open( + os.path.join(intermediates_directory, "module.modulemap") + ) as source_module_map: + for line in source_module_map: + line_to_write = line + match = export_regular_expression.search(line) + if match: + line_to_write = line[: match.start(1)] + line_to_write += module_names_by_relative_include_path[match[2]] + line_to_write += line[match.end(1) :] + destination_module_map.write(line_to_write) + + for directory, modules in sorted_directories_and_modules: + directory_module_attributes = module_attributes.get( + posixpath.relpath(directory, libcxx_include_directory_as_posix), {} + ) + for module in modules: + destination_module_map.write("module ") + destination_module_map.write(module.name) + destination_module_map.write(" [system] {") + + wrote_directory_requires = False + for requires in directory_module_attributes.get("requires", []): + if requires: + destination_module_map.write("\n ") + destination_module_map.write(requires) + wrote_directory_requires = True + if wrote_directory_requires: + destination_module_map.write("\n") + + module_submodule_name_width = 0 + for header in module.headers: + submodule_name_length = len(header.submodule_name) + if submodule_name_length > module_submodule_name_width: + module_submodule_name_width = submodule_name_length + + for header in module.headers: + header_module_attributes = module_attributes.get( + header.libcxx_include_relative_path, {} + ) + needs_multiline = "exports" in header_module_attributes + if not needs_multiline: + # configure_file might have configured all of the requires to "". + for requires in header_module_attributes.get("requires", []): + if requires: + needs_multiline = True + break + + destination_module_map.write("\n module ") + destination_module_map.write( + header.submodule_name.ljust(module_submodule_name_width) + ) + + if needs_multiline: + destination_module_map.write(" {") + for requires in header_module_attributes.get("requires", []): + if requires: + destination_module_map.write("\n ") + destination_module_map.write(requires) + destination_module_map.write("\n ") + else: + destination_module_map.write(" { ") + + if header_module_attributes.get("textual"): + destination_module_map.write("textual ") + destination_module_map.write('header "') + destination_module_map.write(header.libcxx_include_relative_path) + + if needs_multiline: + destination_module_map.write('"') + for export in header_module_attributes.get("exports", []): + # export can be a relative header path in the case of the + # private headers, a module name in the case of the statically + # declared modules, or "*". + exported_module = module_names_by_relative_include_path.get( + export, export + ) + destination_module_map.write("\n export ") + destination_module_map.write(exported_module) + destination_module_map.write("\n }") + else: + destination_module_map.write('" }') + destination_module_map.write("\n}\n") + + +def sanity_check_module_map( + libcxx_include_directory: str, include_tree: typing.Iterable["Header"] +): + with open( + os.path.join(libcxx_include_directory, "module.modulemap") + ) as module_map_file: + module_map_contents = module_map_file.read() + missing_public_headers = [] + missing_private_headers = [] + public_headers_in_multiple_modules = [] + private_headers_in_multiple_modules = [] + for header in include_tree: + if not header.is_libcxx_header: + continue + + # Super basic sanity check: make sure that every header selected by write_libcxx_includes + # ends up in exactly one module in the module map. + header_statement = 'header "' + header.libcxx_include_relative_path + '"' + first_header_match = module_map_contents.find(header_statement) + if first_header_match == -1: + if header.is_private_libcxx_header: + missing_private_headers.append(header) + else: + missing_public_headers.append(header) + elif module_map_contents.find(header_statement, first_header_match + 1) != -1: + if header.is_private_libcxx_header: + private_headers_in_multiple_modules.append(header) + else: + public_headers_in_multiple_modules.append(header) + + if missing_public_headers: + print("module.modulemap.in is missing public headers:") + for header in missing_public_headers: + print(" ", header.libcxx_include_relative_path) + print() + if missing_private_headers: + print("generate_module_map.py failed to generate modules for private headers:") + for header in missing_private_headers: + print(" ", header.libcxx_include_relative_path) + print() + if public_headers_in_multiple_modules: + print("public headers in module.modulemap.in are in multiple modules:") + for header in public_headers_in_multiple_modules: + print(" ", header.libcxx_include_relative_path) + print() + if private_headers_in_multiple_modules: + print( + "private headers generated by generate_module_map.py are in multiple modules:" + ) + for header in private_headers_in_multiple_modules: + print(" ", header.libcxx_include_relative_path) + print() + if ( + missing_public_headers + or missing_private_headers + or public_headers_in_multiple_modules + or private_headers_in_multiple_modules + ): + exit(1) + + +class Header: + def __init__( + self, + path: str, + libcxx_include_directory: str, + module_attributes: typing.Dict[str, dict], + ) -> None: + self.path = path + try: + self.libcxx_include_relative_path = pathlib.PurePath( + os.path.relpath(path, libcxx_include_directory) + ).as_posix() + except ValueError: + self.libcxx_include_relative_path = ".." + if posixpath.commonpath([self.libcxx_include_relative_path, ".."]): + self.is_libcxx_header = False + self.libcxx_include_relative_path = "" + self.is_private_libcxx_header = False + self.module_directory = pathlib.PurePath(os.path.dirname(path)).as_posix() + self.submodule_name = "" + else: + self.is_libcxx_header = True + if self.libcxx_include_relative_path.startswith("__"): + self.is_private_libcxx_header = True + + header_module_attributes = module_attributes.get( + self.libcxx_include_relative_path, {} + ) + + module_directory = header_module_attributes.get("module_directory", "") + if not module_directory: + module_directory_parent = posixpath.dirname( + self.libcxx_include_relative_path + ) + while module_directory_parent: + module_directory = module_directory_parent + module_directory_parent = posixpath.dirname(module_directory) + if module_directory: + self.module_directory = posixpath.join( + pathlib.PurePath(libcxx_include_directory).as_posix(), + module_directory, + ) + else: + self.module_directory = pathlib.PurePath( + libcxx_include_directory + ).as_posix() + + submodule_name = header_module_attributes.get("submodule_name") + if not submodule_name: + path_as_posix = pathlib.PurePath(path).as_posix() + if ( + posixpath.commonpath([path_as_posix, self.module_directory]) + == self.module_directory + ): + submodule_name = posixpath.relpath( + path_as_posix, self.module_directory + ).replace(posixpath.sep, "_") + else: + submodule_name = os.path.basename(path) + if submodule_name.endswith(".h"): + submodule_name = submodule_name[: -len(".h")] + self.submodule_name = submodule_name + else: + self.is_private_libcxx_header = False + self.module_directory = pathlib.PurePath( + os.path.dirname(path) + ).as_posix() + self.submodule_name = "" + + self.including_headers = set() + self.included_headers = set() + self.transitive_including_headers = set() + self.transitive_included_headers = set() + + def __repr__(self) -> str: + return f"<{type(self).__name__} {self.path}>" + + def __hash__(self) -> int: + return hash(self.path) + + def __eq__(self, other) -> bool: + return self.path == other.path + + def __ne__(self, other) -> bool: + return self.path != other.path + + def __lt__(self, other) -> bool: + return self.path < other.path + + def __le__(self, other) -> bool: + return self.path <= other.path + + def __gt__(self, other) -> bool: + return self.path > other.path + + def __ge__(self, other) -> bool: + return self.path >= other.path + + +class Module: + def __init__(self, header: Header) -> None: + self.name = "" + self.headers = [header] + self.transitive_including_headers = header.transitive_including_headers.copy() + self.transitive_included_headers = header.transitive_included_headers.copy() + self.transitive_including_modules = set() + self.transitive_included_modules = set() + + def __repr__(self) -> str: + return f"<{type(self).__name__} headers = {self.headers}>" + + +main() diff --git a/libcxx/include/internal_module_attributes.json.in b/libcxx/include/internal_module_attributes.json.in new file mode 100644 --- /dev/null +++ b/libcxx/include/internal_module_attributes.json.in @@ -0,0 +1,1042 @@ +{ + "__assert": { + "exports": [ + "*" + ] + }, + "__availability": { + "exports": [ + "*" + ] + }, + "__bit_reference": { + "exports": [ + "*" + ] + }, + "__config": { + "textual": true, + "exports": [ + "*" + ] + }, + "__config_site": { + "textual": true + }, + "__hash_table": { + "exports": [ + "*" + ] + }, + "__locale": { + "exports": [ + "*" + ], + "requires": [ + "@requires_LIBCXX_ENABLE_LOCALIZATION@" + ] + }, + "__mbstate_t.h": { + "exports": [ + "*" + ] + }, + "__node_handle": { + "exports": [ + "*" + ] + }, + "__split_buffer": { + "exports": [ + "*" + ] + }, + "__std_mbstate_t.h": { + "exports": [ + "*" + ] + }, + "__threading_support": { + "exports": [ + "*" + ] + }, + "__tree": { + "exports": [ + "*" + ] + }, + "__undef_macros": { + "exports": [ + "*" + ], + "textual": true + }, + "__verbose_abort": { + "exports": [ + "*" + ] + }, + "__algorithm/copy.h": { + "exports": [ + "__algorithm/copy_move_common.h" + ] + }, + "__algorithm/copy_move_common.h": { + "exports": [ + "__type_traits/is_trivially_copyable.h" + ] + }, + "__algorithm/find.h": { + "exports": [ + "__algorithm/unwrap_iter.h" + ] + }, + "__algorithm/iterator_operations.h": { + "exports": [ + "*" + ] + }, + "__algorithm/minmax.h": { + "exports": [ + "*" + ] + }, + "__algorithm/pstl_backend.h": { + "exports": [ + "*" + ] + }, + "__algorithm/pstl_backends/cpu_backend.h": { + "exports": [ + "*" + ] + }, + "__algorithm/pstl_backends/cpu_backends/backend.h": { + "exports": [ + "*" + ] + }, + "__algorithm/pstl_backends/cpu_backends/serial.h": { + "textual": true + }, + "__algorithm/pstl_backends/cpu_backends/thread.h": { + "textual": true + }, + "__algorithm/pstl_backends/cpu_backends/transform.h": { + "exports": [ + "__algorithm/transform.h" + ] + }, + "__algorithm/pstl_find.h": { + "exports": [ + "*" + ] + }, + "__algorithm/pstl_for_each.h": { + "exports": [ + "*" + ] + }, + "__algorithm/pstl_frontend_dispatch.h": { + "exports": [ + "__utility/forward.h" + ] + }, + "__algorithm/pstl_stable_sort.h": { + "exports": [ + "__functional/operations.h" + ] + }, + "__algorithm/ranges_binary_search.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_clamp.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_copy.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_copy_backward.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_copy_if.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_copy_n.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_equal_range.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_for_each.h": { + "exports": [ + "__algorithm/in_fun_result.h" + ] + }, + "__algorithm/ranges_for_each_n.h": { + "exports": [ + "__algorithm/in_fun_result.h" + ] + }, + "__algorithm/ranges_includes.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_inplace_merge.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_is_heap.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_is_heap_until.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_is_sorted.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_is_sorted_until.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_lexicographical_compare.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_lower_bound.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_make_heap.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_max.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_max_element.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_merge.h": { + "exports": [ + "__algorithm/in_in_out_result.h" + ] + }, + "__algorithm/ranges_min.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_min_element.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_minmax.h": { + "exports": [ + "__functional/ranges_operations.h", + "__algorithm/min_max_result.h" + ] + }, + "__algorithm/ranges_minmax_element.h": { + "exports": [ + "__functional/ranges_operations.h", + "__algorithm/min_max_result.h" + ] + }, + "__algorithm/ranges_mismatch.h": { + "exports": [ + "__algorithm/in_in_result.h" + ] + }, + "__algorithm/ranges_move.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_move_backward.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_next_permutation.h": { + "exports": [ + "__algorithm/in_found_result.h", + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_nth_element.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_partial_sort.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_partial_sort_copy.h": { + "exports": [ + "__algorithm/in_out_result.h", + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_pop_heap.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_prev_permutation.h": { + "exports": [ + "__algorithm/in_found_result.h", + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_push_heap.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_remove_copy.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_remove_copy_if.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_replace_copy.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_replace_copy_if.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_reverse_copy.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_rotate_copy.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_set_difference.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_set_intersection.h": { + "exports": [ + "__algorithm/in_in_out_result.h" + ] + }, + "__algorithm/ranges_set_symmetric_difference.h": { + "exports": [ + "__algorithm/in_in_out_result.h", + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_set_union.h": { + "exports": [ + "__algorithm/in_in_out_result.h", + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_sort.h": { + "exports": [ + "__algorithm/make_projected.h", + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_sort_heap.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_stable_sort.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/ranges_swap_ranges.h": { + "exports": [ + "__algorithm/in_in_result.h" + ] + }, + "__algorithm/ranges_transform.h": { + "exports": [ + "__algorithm/in_in_out_result.h", + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_unique_copy.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__algorithm/ranges_upper_bound.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__algorithm/sort.h": { + "exports": [ + "__debug_utils/strict_weak_ordering_check.h" + ] + }, + "__algorithm/swap_ranges.h": { + "exports": [ + "__algorithm/iterator_operations.h" + ] + }, + "__algorithm/unwrap_iter.h": { + "exports": [ + "__iterator/iterator_traits.h" + ] + }, + "__algorithm/unwrap_range.h": { + "exports": [ + "__utility/pair.h" + ] + }, + "__atomic/aliases.h": { + "exports": [ + "__atomic/atomic.h" + ] + }, + "__atomic/atomic.h": { + "exports": [ + "__atomic/atomic_base.h" + ] + }, + "__atomic/atomic_flag.h": { + "exports": [ + "*" + ] + }, + "__chrono/duration.h": { + "exports": [ + "__type_traits/is_convertible.h" + ] + }, + "__chrono/formatter.h": { + "requires": [ + "@requires_LIBCXX_ENABLE_LOCALIZATION@" + ] + }, + "__chrono/high_resolution_clock.h": { + "exports": [ + "__chrono/steady_clock.h", + "__chrono/system_clock.h" + ] + }, + "__chrono/ostream.h": { + "requires": [ + "@requires_LIBCXX_ENABLE_LOCALIZATION@" + ] + }, + "__chrono/parser_std_format_spec.h": { + "requires": [ + "@requires_LIBCXX_ENABLE_LOCALIZATION@" + ] + }, + "__chrono/steady_clock.h": { + "exports": [ + "__chrono/time_point.h" + ] + }, + "__chrono/system_clock.h": { + "exports": [ + "__chrono/time_point.h" + ] + }, + "__concepts/constructible.h": { + "exports": [ + "__concepts/destructible.h" + ] + }, + "__concepts/destructible.h": { + "exports": [ + "__type_traits/is_nothrow_destructible.h" + ] + }, + "__concepts/equality_comparable.h": { + "exports": [ + "__type_traits/common_reference.h" + ] + }, + "__concepts/movable.h": { + "exports": [ + "__type_traits/is_object.h" + ] + }, + "__concepts/same_as.h": { + "exports": [ + "__type_traits/is_same.h" + ] + }, + "__condition_variable/condition_variable.h": { + "exports": [ + "*" + ] + }, + "__debug_utils/strict_weak_ordering_check.h": { + "exports": [ + "__type_traits/is_constant_evaluated.h" + ] + }, + "__exception/exception_ptr.h": { + "exports": [ + "__exception/operations.h" + ] + }, + "__filesystem/directory_entry.h": { + "exports": [ + "*" + ] + }, + "__filesystem/directory_iterator.h": { + "exports": [ + "*" + ] + }, + "__filesystem/filesystem_error.h": { + "exports": [ + "*" + ] + }, + "__filesystem/path.h": { + "exports": [ + "*" + ] + }, + "__filesystem/recursive_directory_iterator.h": { + "exports": [ + "*" + ] + }, + "__format/format_context.h": { + "exports": [ + "*" + ] + }, + "__format/format_functions.h": { + "exports": [ + "std_string" + ] + }, + "__format/format_to_n_result.h": { + "exports": [ + "__iterator/incrementable_traits.h" + ] + }, + "__format/unicode.h": { + "exports": [ + "__format/extended_grapheme_cluster_table.h" + ] + }, + "__functional/boyer_moore_searcher.h": { + "exports": [ + "__memory/shared_ptr.h" + ] + }, + "__functional/compose.h": { + "exports": [ + "__functional/perfect_forward.h" + ] + }, + "__functional/hash.h": { + "exports": [ + "std_cstdint", + "__type_traits/underlying_type.h", + "__utility/pair.h" + ] + }, + "__functional/invoke.h": { + "exports": [ + "*" + ] + }, + "__functional/perfect_forward.h": { + "exports": [ + "*" + ] + }, + "__fwd/array.h": { + "module_directory": "__array", + "submodule_name": "array_fwd" + }, + "__fwd/fstream.h": { + "module_directory": "__iosfwd", + "submodule_name": "fstream_fwd" + }, + "__fwd/get.h": { + "module_directory": "__tuple", + "submodule_name": "get_fwd" + }, + "__fwd/hash.h": { + "module_directory": "__functional", + "submodule_name": "hash_fwd" + }, + "__fwd/ios.h": { + "module_directory": "__iosfwd", + "submodule_name": "ios_fwd" + }, + "__fwd/istream.h": { + "module_directory": "__iosfwd", + "submodule_name": "istream_fwd" + }, + "__fwd/mdspan.h": { + "module_directory": "__mdspan", + "submodule_name": "mdspan_fwd" + }, + "__fwd/memory_resource.h": { + "module_directory": "__memory_resource", + "submodule_name": "memory_resource_fwd" + }, + "__fwd/ostream.h": { + "module_directory": "__iosfwd", + "submodule_name": "ostream_fwd" + }, + "__fwd/pair.h": { + "module_directory": "__utility", + "submodule_name": "pair_fwd" + }, + "__fwd/span.h": { + "module_directory": "__span", + "submodule_name": "span_fwd" + }, + "__fwd/sstream.h": { + "module_directory": "__iosfwd", + "submodule_name": "sstream_fwd" + }, + "__fwd/streambuf.h": { + "module_directory": "__iosfwd", + "submodule_name": "streambuf_fwd" + }, + "__fwd/string.h": { + "module_directory": "__string", + "submodule_name": "string_fwd" + }, + "__fwd/string_view.h": { + "module_directory": "__string_view", + "submodule_name": "string_view_fwd" + }, + "__fwd/subrange.h": { + "module_directory": "__ranges", + "submodule_name": "subrange_fwd", + "exports": [ + "__iterator/concepts.h" + ] + }, + "__fwd/tuple.h": { + "module_directory": "__tuple", + "submodule_name": "tuple_fwd" + }, + "__iterator/concepts.h": { + "exports": [ + "__concepts/constructible.h", + "__concepts/equality_comparable.h", + "__concepts/movable.h", + "__type_traits/common_reference.h", + "__type_traits/is_reference.h", + "__type_traits/remove_cvref.h" + ] + }, + "__iterator/distance.h": { + "exports": [ + "__ranges/size.h" + ] + }, + "__iterator/iterator_traits.h": { + "exports": [ + "__type_traits/is_primary_template.h" + ] + }, + "__iterator/mergeable.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__iterator/ostreambuf_iterator.h": { + "exports": [ + "*" + ] + }, + "__iterator/sortable.h": { + "exports": [ + "__functional/ranges_operations.h" + ] + }, + "__locale_dir/locale_base_api/bsd_locale_defaults.h": { + "textual": true + }, + "__locale_dir/locale_base_api/bsd_locale_fallbacks.h": { + "textual": true + }, + "__mdspan/extents.h": { + "exports": [ + "*" + ] + }, + "__memory/concepts.h": { + "exports": [ + "__type_traits/remove_reference.h" + ] + }, + "__memory/ranges_uninitialized_algorithms.h": { + "exports": [ + "__algorithm/in_out_result.h" + ] + }, + "__memory/shared_ptr.h": { + "exports": [ + "__memory/uninitialized_algorithms.h" + ] + }, + "__memory/uninitialized_algorithms.h": { + "exports": [ + "__algorithm/copy.h" + ] + }, + "__memory/unique_ptr.h": { + "exports": [ + "__type_traits/add_lvalue_reference.h", + "__type_traits/is_pointer.h", + "__type_traits/type_identity.h" + ] + }, + "__memory_resource/synchronized_pool_resource.h": { + "exports": [ + "*" + ] + }, + "__numeric/pstl_transform_reduce.h": { + "exports": [ + "*" + ] + }, + "__random/discrete_distribution.h": { + "exports": [ + "*" + ] + }, + "__random/piecewise_constant_distribution.h": { + "exports": [ + "*" + ] + }, + "__random/piecewise_linear_distribution.h": { + "exports": [ + "*" + ] + }, + "__ranges/all.h": { + "exports": [ + "__functional/compose.h", + "__functional/perfect_forward.h", + "__ranges/owning_view.h" + ] + }, + "__ranges/concepts.h": { + "exports": [ + "__iterator/concepts.h" + ] + }, + "__ranges/counted.h": { + "exports": [ + "std_span" + ] + }, + "__ranges/filter_view.h": { + "exports": [ + "__ranges/range_adaptor.h" + ] + }, + "__ranges/istream_view.h": { + "requires": [ + "@requires_LIBCXX_ENABLE_LOCALIZATION@" + ] + }, + "__ranges/join_view.h": { + "exports": [ + "__iterator/iterator_with_data.h", + "__iterator/segmented_iterator.h" + ] + }, + "__ranges/lazy_split_view.h": { + "exports": [ + "__ranges/non_propagating_cache.h" + ] + }, + "__ranges/size.h": { + "exports": [ + "__type_traits/make_unsigned.h" + ] + }, + "__ranges/subrange.h": { + "exports": [ + "__fwd/subrange.h" + ] + }, + "__ranges/transform_view.h": { + "exports": [ + "__functional/bind_back.h", + "__functional/perfect_forward.h", + "__ranges/movable_box.h" + ] + }, + "__stop_token/stop_source.h": { + "exports": [ + "*" + ] + }, + "__stop_token/stop_state.h": { + "exports": [ + "*" + ] + }, + "__stop_token/stop_token.h": { + "exports": [ + "*" + ] + }, + "__string/constexpr_c_functions.h": { + "exports": [ + "__type_traits/is_equality_comparable.h" + ] + }, + "__system_error/error_code.h": { + "exports": [ + "__functional/hash.h", + "__functional/unary_function.h" + ] + }, + "__system_error/error_condition.h": { + "exports": [ + "__functional/hash.h", + "__functional/unary_function.h" + ] + }, + "__thread/thread.h": { + "exports": [ + "*" + ] + }, + "__tuple/pair_like.h": { + "exports": [ + "__tuple/tuple_like.h" + ] + }, + "__type_traits/add_lvalue_reference.h": { + "exports": [ + "__type_traits/is_referenceable.h" + ] + }, + "__type_traits/apply_cv.h": { + "exports": [ + "__type_traits/is_const.h", + "__type_traits/is_volatile.h" + ] + }, + "__type_traits/common_reference.h": { + "exports": [ + "__type_traits/remove_cvref.h" + ] + }, + "__type_traits/common_type.h": { + "exports": [ + "__utility/declval.h" + ] + }, + "__type_traits/decay.h": { + "exports": [ + "__type_traits/add_pointer.h" + ] + }, + "__type_traits/invoke.h": { + "exports": [ + "__type_traits/conditional.h", + "__type_traits/decay.h", + "__type_traits/enable_if.h", + "__type_traits/is_base_of.h", + "__type_traits/is_core_convertible.h", + "__type_traits/is_reference_wrapper.h", + "__type_traits/is_same.h", + "__type_traits/is_void.h", + "__type_traits/nat.h", + "__type_traits/remove_cv.h" + ] + }, + "__type_traits/is_arithmetic.h": { + "exports": [ + "__type_traits/integral_constant.h" + ] + }, + "__type_traits/is_array.h": { + "exports": [ + "__type_traits/integral_constant.h" + ] + }, + "__type_traits/is_convertible.h": { + "exports": [ + "__type_traits/is_array.h" + ] + }, + "__type_traits/is_core_convertible.h": { + "exports": [ + "__type_traits/integral_constant.h" + ] + }, + "__type_traits/is_enum.h": { + "exports": [ + "__type_traits/integral_constant.h" + ] + }, + "__type_traits/is_equality_comparable.h": { + "exports": [ + "__type_traits/integral_constant.h" + ] + }, + "__type_traits/is_execution_policy.h": { + "exports": [ + "__type_traits/remove_cvref.h" + ] + }, + "__type_traits/is_nothrow_destructible.h": { + "exports": [ + "__type_traits/is_destructible.h" + ] + }, + "__type_traits/is_nothrow_move_constructible.h": { + "exports": [ + "__type_traits/is_nothrow_constructible.h" + ] + }, + "__type_traits/is_null_pointer.h": { + "exports": [ + "std_cstddef" + ] + }, + "__type_traits/is_object.h": { + "exports": [ + "__type_traits/is_scalar.h" + ] + }, + "__type_traits/is_primary_template.h": { + "exports": [ + "__type_traits/enable_if.h" + ] + }, + "__type_traits/is_same.h": { + "exports": [ + "__type_traits/integral_constant.h" + ] + }, + "__type_traits/is_scalar.h": { + "exports": [ + "__type_traits/is_null_pointer.h" + ] + }, + "__type_traits/is_swappable.h": { + "exports": [ + "__type_traits/is_move_constructible.h" + ] + }, + "__type_traits/is_void.h": { + "exports": [ + "__type_traits/integral_constant.h" + ] + }, + "__type_traits/make_unsigned.h": { + "exports": [ + "__type_traits/is_unsigned.h" + ] + }, + "__type_traits/remove_cv.h": { + "exports": [ + "__type_traits/remove_const.h", + "__type_traits/remove_volatile.h" + ] + }, + "__type_traits/underlying_type.h": { + "exports": [ + "__type_traits/is_enum.h" + ] + }, + "__utility/auto_cast.h": { + "exports": [ + "__type_traits/decay.h" + ] + }, + "__utility/cmp.h": { + "exports": [ + "__type_traits/make_unsigned.h" + ] + }, + "__utility/move.h": { + "exports": [ + "__type_traits/is_copy_constructible.h", + "__type_traits/is_nothrow_move_constructible.h", + "__type_traits/remove_reference.h" + ] + }, + "__utility/pair.h": { + "exports": [ + "__fwd/pair.h", + "__fwd/subrange.h", + "__tuple/pair_like.h", + "__type_traits/is_assignable.h", + "__type_traits/is_constructible.h", + "__type_traits/is_convertible.h", + "__type_traits/is_copy_assignable.h", + "__type_traits/is_move_assignable.h", + "__type_traits/is_nothrow_copy_constructible.h", + "__type_traits/is_nothrow_default_constructible.h", + "__type_traits/is_nothrow_move_assignable.h" + ] + }, + "__utility/swap.h": { + "exports": [ + "__type_traits/is_swappable.h" + ] + } +} diff --git a/libcxx/include/module.modulemap.in b/libcxx/include/module.modulemap.in --- a/libcxx/include/module.modulemap.in +++ b/libcxx/include/module.modulemap.in @@ -245,9 +245,9 @@ } module std_span [system] { header "span" - export std_private_ranges_enable_borrowed_range + export "__ranges/enable_borrowed_range.h" export std_version - export std_private_span_span_fwd + export "__fwd/span.h" } module std_sstream [system] { @requires_LIBCXX_ENABLE_LOCALIZATION@ @@ -629,1446 +629,3 @@ // Implementation detail headers that are private to libc++. These modules // must not be directly imported. -module std_private_assert [system] { - header "__assert" - export * -} -module std_private_availability [system] { - header "__availability" - export * -} -module std_private_bit_reference [system] { - header "__bit_reference" - export * -} -module std_private_config [system] { - textual header "__config" - export * -} -module std_private_hash_table [system] { - header "__hash_table" - export * -} -module std_private_locale [system] { - @requires_LIBCXX_ENABLE_LOCALIZATION@ - header "__locale" - export * -} -module std_private_mbstate_t [system] { - header "__mbstate_t.h" - export * -} -module std_private_node_handle [system] { - header "__node_handle" - export * -} -module std_private_split_buffer [system] { - header "__split_buffer" - export * -} -module std_private_std_mbstate_t [system] { - header "__std_mbstate_t.h" - export * -} -module std_private_threading_support [system] { - header "__threading_support" - export * -} -module std_private_tree [system] { - header "__tree" - export * -} -module std_private_undef_macros [system] { - textual header "__undef_macros" - export * -} -module std_private_verbose_abort [system] { - header "__verbose_abort" - export * -} - -module std_private_algorithm_adjacent_find [system] { header "__algorithm/adjacent_find.h" } -module std_private_algorithm_all_of [system] { header "__algorithm/all_of.h" } -module std_private_algorithm_any_of [system] { header "__algorithm/any_of.h" } -module std_private_algorithm_binary_search [system] { header "__algorithm/binary_search.h" } -module std_private_algorithm_clamp [system] { header "__algorithm/clamp.h" } -module std_private_algorithm_comp [system] { header "__algorithm/comp.h" } -module std_private_algorithm_comp_ref_type [system] { header "__algorithm/comp_ref_type.h" } -module std_private_algorithm_copy [system] { - header "__algorithm/copy.h" - export std_private_algorithm_copy_move_common -} -module std_private_algorithm_copy_backward [system] { header "__algorithm/copy_backward.h" } -module std_private_algorithm_copy_if [system] { header "__algorithm/copy_if.h" } -module std_private_algorithm_copy_move_common [system] { - header "__algorithm/copy_move_common.h" - export std_private_type_traits_is_trivially_copyable -} -module std_private_algorithm_copy_n [system] { header "__algorithm/copy_n.h" } -module std_private_algorithm_count [system] { header "__algorithm/count.h" } -module std_private_algorithm_count_if [system] { header "__algorithm/count_if.h" } -module std_private_algorithm_equal [system] { header "__algorithm/equal.h" } -module std_private_algorithm_equal_range [system] { header "__algorithm/equal_range.h" } -module std_private_algorithm_fill [system] { header "__algorithm/fill.h" } -module std_private_algorithm_fill_n [system] { header "__algorithm/fill_n.h" } -module std_private_algorithm_find [system] { - header "__algorithm/find.h" - export std_private_algorithm_unwrap_iter -} -module std_private_algorithm_find_end [system] { header "__algorithm/find_end.h" } -module std_private_algorithm_find_first_of [system] { header "__algorithm/find_first_of.h" } -module std_private_algorithm_find_if [system] { header "__algorithm/find_if.h" } -module std_private_algorithm_find_if_not [system] { header "__algorithm/find_if_not.h" } -module std_private_algorithm_for_each [system] { header "__algorithm/for_each.h" } -module std_private_algorithm_for_each_n [system] { header "__algorithm/for_each_n.h" } -module std_private_algorithm_for_each_segment [system] { header "__algorithm/for_each_segment.h" } -module std_private_algorithm_generate [system] { header "__algorithm/generate.h" } -module std_private_algorithm_generate_n [system] { header "__algorithm/generate_n.h" } -module std_private_algorithm_half_positive [system] { header "__algorithm/half_positive.h" } -module std_private_algorithm_in_found_result [system] { header "__algorithm/in_found_result.h" } -module std_private_algorithm_in_fun_result [system] { header "__algorithm/in_fun_result.h" } -module std_private_algorithm_in_in_out_result [system] { header "__algorithm/in_in_out_result.h" } -module std_private_algorithm_in_in_result [system] { header "__algorithm/in_in_result.h" } -module std_private_algorithm_in_out_out_result [system] { header "__algorithm/in_out_out_result.h" } -module std_private_algorithm_in_out_result [system] { header "__algorithm/in_out_result.h" } -module std_private_algorithm_includes [system] { header "__algorithm/includes.h" } -module std_private_algorithm_inplace_merge [system] { header "__algorithm/inplace_merge.h" } -module std_private_algorithm_is_heap [system] { header "__algorithm/is_heap.h" } -module std_private_algorithm_is_heap_until [system] { header "__algorithm/is_heap_until.h" } -module std_private_algorithm_is_partitioned [system] { header "__algorithm/is_partitioned.h" } -module std_private_algorithm_is_permutation [system] { header "__algorithm/is_permutation.h" } -module std_private_algorithm_is_sorted [system] { header "__algorithm/is_sorted.h" } -module std_private_algorithm_is_sorted_until [system] { header "__algorithm/is_sorted_until.h" } -module std_private_algorithm_iter_swap [system] { header "__algorithm/iter_swap.h" } -module std_private_algorithm_iterator_operations [system] { - header "__algorithm/iterator_operations.h" - export * -} -module std_private_algorithm_lexicographical_compare [system] { header "__algorithm/lexicographical_compare.h" } -module std_private_algorithm_lexicographical_compare_three_way [system] { header "__algorithm/lexicographical_compare_three_way.h" } -module std_private_algorithm_lower_bound [system] { header "__algorithm/lower_bound.h" } -module std_private_algorithm_make_heap [system] { header "__algorithm/make_heap.h" } -module std_private_algorithm_make_projected [system] { header "__algorithm/make_projected.h" } -module std_private_algorithm_max [system] { header "__algorithm/max.h" } -module std_private_algorithm_max_element [system] { header "__algorithm/max_element.h" } -module std_private_algorithm_merge [system] { header "__algorithm/merge.h" } -module std_private_algorithm_min [system] { header "__algorithm/min.h" } -module std_private_algorithm_min_element [system] { header "__algorithm/min_element.h" } -module std_private_algorithm_min_max_result [system] { header "__algorithm/min_max_result.h" } -module std_private_algorithm_minmax [system] { - header "__algorithm/minmax.h" - export * -} -module std_private_algorithm_minmax_element [system] { header "__algorithm/minmax_element.h" } -module std_private_algorithm_mismatch [system] { header "__algorithm/mismatch.h" } -module std_private_algorithm_move [system] { header "__algorithm/move.h" } -module std_private_algorithm_move_backward [system] { header "__algorithm/move_backward.h" } -module std_private_algorithm_next_permutation [system] { header "__algorithm/next_permutation.h" } -module std_private_algorithm_none_of [system] { header "__algorithm/none_of.h" } -module std_private_algorithm_nth_element [system] { header "__algorithm/nth_element.h" } -module std_private_algorithm_partial_sort [system] { header "__algorithm/partial_sort.h" } -module std_private_algorithm_partial_sort_copy [system] { header "__algorithm/partial_sort_copy.h" } -module std_private_algorithm_partition [system] { header "__algorithm/partition.h" } -module std_private_algorithm_partition_copy [system] { header "__algorithm/partition_copy.h" } -module std_private_algorithm_partition_point [system] { header "__algorithm/partition_point.h" } -module std_private_algorithm_pop_heap [system] { header "__algorithm/pop_heap.h" } -module std_private_algorithm_prev_permutation [system] { header "__algorithm/prev_permutation.h" } -module std_private_algorithm_pstl_any_all_none_of [system] { header "__algorithm/pstl_any_all_none_of.h" } -module std_private_algorithm_pstl_backend [system] { - header "__algorithm/pstl_backend.h" - export * -} -module std_private_algorithm_pstl_backends_cpu_backend [system] { - header "__algorithm/pstl_backends/cpu_backend.h" - export * -} -module std_private_algorithm_pstl_backends_cpu_backends_any_of [system] { header "__algorithm/pstl_backends/cpu_backends/any_of.h" } -module std_private_algorithm_pstl_backends_cpu_backends_backend [system] { - header "__algorithm/pstl_backends/cpu_backends/backend.h" - export * -} -module std_private_algorithm_pstl_backends_cpu_backends_fill [system] { header "__algorithm/pstl_backends/cpu_backends/fill.h" } -module std_private_algorithm_pstl_backends_cpu_backends_find_if [system] { header "__algorithm/pstl_backends/cpu_backends/find_if.h" } -module std_private_algorithm_pstl_backends_cpu_backends_for_each [system] { header "__algorithm/pstl_backends/cpu_backends/for_each.h" } -module std_private_algorithm_pstl_backends_cpu_backends_libdispatch [system] { header "__algorithm/pstl_backends/cpu_backends/libdispatch.h" } -module std_private_algorithm_pstl_backends_cpu_backends_merge [system] { header "__algorithm/pstl_backends/cpu_backends/merge.h" } -module std_private_algorithm_pstl_backends_cpu_backends_serial [system] { textual header "__algorithm/pstl_backends/cpu_backends/serial.h" } -module std_private_algorithm_pstl_backends_cpu_backends_stable_sort [system] { header "__algorithm/pstl_backends/cpu_backends/stable_sort.h" } -module std_private_algorithm_pstl_backends_cpu_backends_thread [system] { textual header "__algorithm/pstl_backends/cpu_backends/thread.h" } -module std_private_algorithm_pstl_backends_cpu_backends_transform [system] { - header "__algorithm/pstl_backends/cpu_backends/transform.h" - export std_private_algorithm_transform -} -module std_private_algorithm_pstl_backends_cpu_backends_transform_reduce [system] { header "__algorithm/pstl_backends/cpu_backends/transform_reduce.h" } -module std_private_algorithm_pstl_copy [system] { header "__algorithm/pstl_copy.h" } -module std_private_algorithm_pstl_count [system] { header "__algorithm/pstl_count.h" } -module std_private_algorithm_pstl_fill [system] { header "__algorithm/pstl_fill.h" } -module std_private_algorithm_pstl_find [system] { - header "__algorithm/pstl_find.h" - export * -} -module std_private_algorithm_pstl_for_each [system] { - header "__algorithm/pstl_for_each.h" - export * -} -module std_private_algorithm_pstl_frontend_dispatch [system] { - header "__algorithm/pstl_frontend_dispatch.h" - export std_private_utility_forward -} -module std_private_algorithm_pstl_generate [system] { header "__algorithm/pstl_generate.h" } -module std_private_algorithm_pstl_is_partitioned [system] { header "__algorithm/pstl_is_partitioned.h" } -module std_private_algorithm_pstl_merge [system] { header "__algorithm/pstl_merge.h" } -module std_private_algorithm_pstl_replace [system] { header "__algorithm/pstl_replace.h" } -module std_private_algorithm_pstl_stable_sort [system] { - header "__algorithm/pstl_stable_sort.h" - export std_private_functional_operations -} -module std_private_algorithm_pstl_transform [system] { header "__algorithm/pstl_transform.h" } -module std_private_algorithm_push_heap [system] { header "__algorithm/push_heap.h" } -module std_private_algorithm_ranges_adjacent_find [system] { header "__algorithm/ranges_adjacent_find.h" } -module std_private_algorithm_ranges_all_of [system] { header "__algorithm/ranges_all_of.h" } -module std_private_algorithm_ranges_any_of [system] { header "__algorithm/ranges_any_of.h" } -module std_private_algorithm_ranges_binary_search [system] { - header "__algorithm/ranges_binary_search.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_clamp [system] { - header "__algorithm/ranges_clamp.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_copy [system] { - header "__algorithm/ranges_copy.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_copy_backward [system] { - header "__algorithm/ranges_copy_backward.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_copy_if [system] { - header "__algorithm/ranges_copy_if.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_copy_n [system] { - header "__algorithm/ranges_copy_n.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_count [system] { header "__algorithm/ranges_count.h" } -module std_private_algorithm_ranges_count_if [system] { header "__algorithm/ranges_count_if.h" } -module std_private_algorithm_ranges_equal [system] { header "__algorithm/ranges_equal.h" } -module std_private_algorithm_ranges_equal_range [system] { - header "__algorithm/ranges_equal_range.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_fill [system] { header "__algorithm/ranges_fill.h" } -module std_private_algorithm_ranges_fill_n [system] { header "__algorithm/ranges_fill_n.h" } -module std_private_algorithm_ranges_find [system] { header "__algorithm/ranges_find.h" } -module std_private_algorithm_ranges_find_end [system] { header "__algorithm/ranges_find_end.h" } -module std_private_algorithm_ranges_find_first_of [system] { header "__algorithm/ranges_find_first_of.h" } -module std_private_algorithm_ranges_find_if [system] { header "__algorithm/ranges_find_if.h" } -module std_private_algorithm_ranges_find_if_not [system] { header "__algorithm/ranges_find_if_not.h" } -module std_private_algorithm_ranges_for_each [system] { - header "__algorithm/ranges_for_each.h" - export std_private_algorithm_in_fun_result -} -module std_private_algorithm_ranges_for_each_n [system] { - header "__algorithm/ranges_for_each_n.h" - export std_private_algorithm_in_fun_result -} -module std_private_algorithm_ranges_generate [system] { header "__algorithm/ranges_generate.h" } -module std_private_algorithm_ranges_generate_n [system] { header "__algorithm/ranges_generate_n.h" } -module std_private_algorithm_ranges_includes [system] { - header "__algorithm/ranges_includes.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_inplace_merge [system] { - header "__algorithm/ranges_inplace_merge.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_is_heap [system] { - header "__algorithm/ranges_is_heap.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_is_heap_until [system] { - header "__algorithm/ranges_is_heap_until.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_is_partitioned [system] { header "__algorithm/ranges_is_partitioned.h" } -module std_private_algorithm_ranges_is_permutation [system] { header "__algorithm/ranges_is_permutation.h" } -module std_private_algorithm_ranges_is_sorted [system] { - header "__algorithm/ranges_is_sorted.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_is_sorted_until [system] { - header "__algorithm/ranges_is_sorted_until.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_iterator_concept [system] { header "__algorithm/ranges_iterator_concept.h" } -module std_private_algorithm_ranges_lexicographical_compare [system] { - header "__algorithm/ranges_lexicographical_compare.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_lower_bound [system] { - header "__algorithm/ranges_lower_bound.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_make_heap [system] { - header "__algorithm/ranges_make_heap.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_max [system] { - header "__algorithm/ranges_max.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_max_element [system] { - header "__algorithm/ranges_max_element.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_merge [system] { - header "__algorithm/ranges_merge.h" - export std_private_algorithm_in_in_out_result -} -module std_private_algorithm_ranges_min [system] { - header "__algorithm/ranges_min.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_min_element [system] { - header "__algorithm/ranges_min_element.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_minmax [system] { - header "__algorithm/ranges_minmax.h" - export std_private_functional_ranges_operations - export std_private_algorithm_min_max_result -} -module std_private_algorithm_ranges_minmax_element [system] { - header "__algorithm/ranges_minmax_element.h" - export std_private_functional_ranges_operations - export std_private_algorithm_min_max_result -} -module std_private_algorithm_ranges_mismatch [system] { - header "__algorithm/ranges_mismatch.h" - export std_private_algorithm_in_in_result -} -module std_private_algorithm_ranges_move [system] { - header "__algorithm/ranges_move.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_move_backward [system] { - header "__algorithm/ranges_move_backward.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_next_permutation [system] { - header "__algorithm/ranges_next_permutation.h" - export std_private_algorithm_in_found_result - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_none_of [system] { header "__algorithm/ranges_none_of.h" } -module std_private_algorithm_ranges_nth_element [system] { - header "__algorithm/ranges_nth_element.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_partial_sort [system] { - header "__algorithm/ranges_partial_sort.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_partial_sort_copy [system] { - header "__algorithm/ranges_partial_sort_copy.h" - export std_private_algorithm_in_out_result - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_partition [system] { header "__algorithm/ranges_partition.h" } -module std_private_algorithm_ranges_partition_copy [system] { header "__algorithm/ranges_partition_copy.h" } -module std_private_algorithm_ranges_partition_point [system] { header "__algorithm/ranges_partition_point.h" } -module std_private_algorithm_ranges_pop_heap [system] { - header "__algorithm/ranges_pop_heap.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_prev_permutation [system] { - header "__algorithm/ranges_prev_permutation.h" - export std_private_algorithm_in_found_result - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_push_heap [system] { - header "__algorithm/ranges_push_heap.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_remove [system] { header "__algorithm/ranges_remove.h" } -module std_private_algorithm_ranges_remove_copy [system] { - header "__algorithm/ranges_remove_copy.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_remove_copy_if [system] { - header "__algorithm/ranges_remove_copy_if.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_remove_if [system] { header "__algorithm/ranges_remove_if.h" } -module std_private_algorithm_ranges_replace [system] { header "__algorithm/ranges_replace.h" } -module std_private_algorithm_ranges_replace_copy [system] { - header "__algorithm/ranges_replace_copy.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_replace_copy_if [system] { - header "__algorithm/ranges_replace_copy_if.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_replace_if [system] { header "__algorithm/ranges_replace_if.h" } -module std_private_algorithm_ranges_reverse [system] { header "__algorithm/ranges_reverse.h" } -module std_private_algorithm_ranges_reverse_copy [system] { - header "__algorithm/ranges_reverse_copy.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_rotate [system] { header "__algorithm/ranges_rotate.h" } -module std_private_algorithm_ranges_rotate_copy [system] { - header "__algorithm/ranges_rotate_copy.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_sample [system] { header "__algorithm/ranges_sample.h" } -module std_private_algorithm_ranges_search [system] { header "__algorithm/ranges_search.h" } -module std_private_algorithm_ranges_search_n [system] { header "__algorithm/ranges_search_n.h" } -module std_private_algorithm_ranges_set_difference [system] { - header "__algorithm/ranges_set_difference.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_set_intersection [system] { - header "__algorithm/ranges_set_intersection.h" - export std_private_algorithm_in_in_out_result -} -module std_private_algorithm_ranges_set_symmetric_difference [system] { - header "__algorithm/ranges_set_symmetric_difference.h" - export std_private_algorithm_in_in_out_result - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_set_union [system] { - header "__algorithm/ranges_set_union.h" - export std_private_algorithm_in_in_out_result - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_shuffle [system] { header "__algorithm/ranges_shuffle.h" } -module std_private_algorithm_ranges_sort [system] { - header "__algorithm/ranges_sort.h" - export std_private_algorithm_make_projected - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_sort_heap [system] { - header "__algorithm/ranges_sort_heap.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_stable_partition [system] { header "__algorithm/ranges_stable_partition.h" } -module std_private_algorithm_ranges_stable_sort [system] { - header "__algorithm/ranges_stable_sort.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_ranges_starts_with [system] { header "__algorithm/ranges_starts_with.h" } -module std_private_algorithm_ranges_swap_ranges [system] { - header "__algorithm/ranges_swap_ranges.h" - export std_private_algorithm_in_in_result -} -module std_private_algorithm_ranges_transform [system] { - header "__algorithm/ranges_transform.h" - export std_private_algorithm_in_in_out_result - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_unique [system] { header "__algorithm/ranges_unique.h" } -module std_private_algorithm_ranges_unique_copy [system] { - header "__algorithm/ranges_unique_copy.h" - export std_private_algorithm_in_out_result -} -module std_private_algorithm_ranges_upper_bound [system] { - header "__algorithm/ranges_upper_bound.h" - export std_private_functional_ranges_operations -} -module std_private_algorithm_remove [system] { header "__algorithm/remove.h" } -module std_private_algorithm_remove_copy [system] { header "__algorithm/remove_copy.h" } -module std_private_algorithm_remove_copy_if [system] { header "__algorithm/remove_copy_if.h" } -module std_private_algorithm_remove_if [system] { header "__algorithm/remove_if.h" } -module std_private_algorithm_replace [system] { header "__algorithm/replace.h" } -module std_private_algorithm_replace_copy [system] { header "__algorithm/replace_copy.h" } -module std_private_algorithm_replace_copy_if [system] { header "__algorithm/replace_copy_if.h" } -module std_private_algorithm_replace_if [system] { header "__algorithm/replace_if.h" } -module std_private_algorithm_reverse [system] { header "__algorithm/reverse.h" } -module std_private_algorithm_reverse_copy [system] { header "__algorithm/reverse_copy.h" } -module std_private_algorithm_rotate [system] { header "__algorithm/rotate.h" } -module std_private_algorithm_rotate_copy [system] { header "__algorithm/rotate_copy.h" } -module std_private_algorithm_sample [system] { header "__algorithm/sample.h" } -module std_private_algorithm_search [system] { header "__algorithm/search.h" } -module std_private_algorithm_search_n [system] { header "__algorithm/search_n.h" } -module std_private_algorithm_set_difference [system] { header "__algorithm/set_difference.h" } -module std_private_algorithm_set_intersection [system] { header "__algorithm/set_intersection.h" } -module std_private_algorithm_set_symmetric_difference [system] { header "__algorithm/set_symmetric_difference.h" } -module std_private_algorithm_set_union [system] { header "__algorithm/set_union.h" } -module std_private_algorithm_shift_left [system] { header "__algorithm/shift_left.h" } -module std_private_algorithm_shift_right [system] { header "__algorithm/shift_right.h" } -module std_private_algorithm_shuffle [system] { header "__algorithm/shuffle.h" } -module std_private_algorithm_sift_down [system] { header "__algorithm/sift_down.h" } -module std_private_algorithm_sort [system] { - header "__algorithm/sort.h" - export std_private_debug_utils_strict_weak_ordering_check -} -module std_private_algorithm_sort_heap [system] { header "__algorithm/sort_heap.h" } -module std_private_algorithm_stable_partition [system] { header "__algorithm/stable_partition.h" } -module std_private_algorithm_stable_sort [system] { header "__algorithm/stable_sort.h" } -module std_private_algorithm_swap_ranges [system] { - header "__algorithm/swap_ranges.h" - export std_private_algorithm_iterator_operations -} -module std_private_algorithm_three_way_comp_ref_type [system] { header "__algorithm/three_way_comp_ref_type.h" } -module std_private_algorithm_transform [system] { header "__algorithm/transform.h" } -module std_private_algorithm_uniform_random_bit_generator_adaptor [system] { header "__algorithm/uniform_random_bit_generator_adaptor.h" } -module std_private_algorithm_unique [system] { header "__algorithm/unique.h" } -module std_private_algorithm_unique_copy [system] { header "__algorithm/unique_copy.h" } -module std_private_algorithm_unwrap_iter [system] { - header "__algorithm/unwrap_iter.h" - export std_private_iterator_iterator_traits -} -module std_private_algorithm_unwrap_range [system] { - header "__algorithm/unwrap_range.h" - export std_private_utility_pair -} -module std_private_algorithm_upper_bound [system] { header "__algorithm/upper_bound.h" } - -module std_private_array_array_fwd [system] { header "__fwd/array.h" } - -module std_private_atomic_aliases [system] { - header "__atomic/aliases.h" - export std_private_atomic_atomic -} -module std_private_atomic_atomic [system] { - header "__atomic/atomic.h" - export std_private_atomic_atomic_base -} -module std_private_atomic_atomic_base [system] { header "__atomic/atomic_base.h" } -module std_private_atomic_atomic_flag [system] { - header "__atomic/atomic_flag.h" - export * -} -module std_private_atomic_atomic_init [system] { header "__atomic/atomic_init.h" } -module std_private_atomic_atomic_lock_free [system] { header "__atomic/atomic_lock_free.h" } -module std_private_atomic_atomic_sync [system] { header "__atomic/atomic_sync.h" } -module std_private_atomic_check_memory_order [system] { header "__atomic/check_memory_order.h" } -module std_private_atomic_contention_t [system] { header "__atomic/contention_t.h" } -module std_private_atomic_cxx_atomic_impl [system] { header "__atomic/cxx_atomic_impl.h" } -module std_private_atomic_fence [system] { header "__atomic/fence.h" } -module std_private_atomic_is_always_lock_free [system] { header "__atomic/is_always_lock_free.h" } -module std_private_atomic_kill_dependency [system] { header "__atomic/kill_dependency.h" } -module std_private_atomic_memory_order [system] { header "__atomic/memory_order.h" } - -module std_private_bit_bit_cast [system] { header "__bit/bit_cast.h" } -module std_private_bit_bit_ceil [system] { header "__bit/bit_ceil.h" } -module std_private_bit_bit_floor [system] { header "__bit/bit_floor.h" } -module std_private_bit_bit_log2 [system] { header "__bit/bit_log2.h" } -module std_private_bit_bit_width [system] { header "__bit/bit_width.h" } -module std_private_bit_blsr [system] { header "__bit/blsr.h" } -module std_private_bit_byteswap [system] { header "__bit/byteswap.h" } -module std_private_bit_countl [system] { header "__bit/countl.h" } -module std_private_bit_countr [system] { header "__bit/countr.h" } -module std_private_bit_endian [system] { header "__bit/endian.h" } -module std_private_bit_has_single_bit [system] { header "__bit/has_single_bit.h" } -module std_private_bit_popcount [system] { header "__bit/popcount.h" } -module std_private_bit_rotate [system] { header "__bit/rotate.h" } - -module std_private_charconv_chars_format [system] { header "__charconv/chars_format.h" } -module std_private_charconv_from_chars_integral [system] { header "__charconv/from_chars_integral.h" } -module std_private_charconv_from_chars_result [system] { header "__charconv/from_chars_result.h" } -module std_private_charconv_tables [system] { header "__charconv/tables.h" } -module std_private_charconv_to_chars [system] { header "__charconv/to_chars.h" } -module std_private_charconv_to_chars_base_10 [system] { header "__charconv/to_chars_base_10.h" } -module std_private_charconv_to_chars_floating_point [system] { header "__charconv/to_chars_floating_point.h" } -module std_private_charconv_to_chars_integral [system] { header "__charconv/to_chars_integral.h" } -module std_private_charconv_to_chars_result [system] { header "__charconv/to_chars_result.h" } -module std_private_charconv_traits [system] { header "__charconv/traits.h" } - -module std_private_chrono_calendar [system] { header "__chrono/calendar.h" } -module std_private_chrono_concepts [system] { header "__chrono/concepts.h" } -module std_private_chrono_convert_to_timespec [system] { header "__chrono/convert_to_timespec.h" } -module std_private_chrono_convert_to_tm [system] { header "__chrono/convert_to_tm.h" } -module std_private_chrono_day [system] { header "__chrono/day.h" } -module std_private_chrono_duration [system] { - header "__chrono/duration.h" - export std_private_type_traits_is_convertible -} -module std_private_chrono_file_clock [system] { header "__chrono/file_clock.h" } -module std_private_chrono_formatter [system] { - @requires_LIBCXX_ENABLE_LOCALIZATION@ - header "__chrono/formatter.h" -} -module std_private_chrono_hh_mm_ss [system] { header "__chrono/hh_mm_ss.h" } -module std_private_chrono_high_resolution_clock [system] { - header "__chrono/high_resolution_clock.h" - export std_private_chrono_steady_clock - export std_private_chrono_system_clock -} -module std_private_chrono_literals [system] { header "__chrono/literals.h" } -module std_private_chrono_month [system] { header "__chrono/month.h" } -module std_private_chrono_month_weekday [system] { header "__chrono/month_weekday.h" } -module std_private_chrono_monthday [system] { header "__chrono/monthday.h" } -module std_private_chrono_ostream [system] { - @requires_LIBCXX_ENABLE_LOCALIZATION@ - header "__chrono/ostream.h" -} -module std_private_chrono_parser_std_format_spec [system] { - @requires_LIBCXX_ENABLE_LOCALIZATION@ - header "__chrono/parser_std_format_spec.h" -} -module std_private_chrono_statically_widen [system] { header "__chrono/statically_widen.h" } -module std_private_chrono_steady_clock [system] { - header "__chrono/steady_clock.h" - export std_private_chrono_time_point -} -module std_private_chrono_system_clock [system] { - header "__chrono/system_clock.h" - export std_private_chrono_time_point -} -module std_private_chrono_time_point [system] { header "__chrono/time_point.h" } -module std_private_chrono_weekday [system] { header "__chrono/weekday.h" } -module std_private_chrono_year [system] { header "__chrono/year.h" } -module std_private_chrono_year_month [system] { header "__chrono/year_month.h" } -module std_private_chrono_year_month_day [system] { header "__chrono/year_month_day.h" } -module std_private_chrono_year_month_weekday [system] { header "__chrono/year_month_weekday.h" } - -module std_private_compare_common_comparison_category [system] { header "__compare/common_comparison_category.h" } -module std_private_compare_compare_partial_order_fallback [system] { header "__compare/compare_partial_order_fallback.h" } -module std_private_compare_compare_strong_order_fallback [system] { header "__compare/compare_strong_order_fallback.h" } -module std_private_compare_compare_three_way [system] { header "__compare/compare_three_way.h" } -module std_private_compare_compare_three_way_result [system] { header "__compare/compare_three_way_result.h" } -module std_private_compare_compare_weak_order_fallback [system] { header "__compare/compare_weak_order_fallback.h" } -module std_private_compare_is_eq [system] { header "__compare/is_eq.h" } -module std_private_compare_ordering [system] { header "__compare/ordering.h" } -module std_private_compare_partial_order [system] { header "__compare/partial_order.h" } -module std_private_compare_strong_order [system] { header "__compare/strong_order.h" } -module std_private_compare_synth_three_way [system] { header "__compare/synth_three_way.h" } -module std_private_compare_three_way_comparable [system] { header "__compare/three_way_comparable.h" } -module std_private_compare_weak_order [system] { header "__compare/weak_order.h" } - -module std_private_concepts_arithmetic [system] { header "__concepts/arithmetic.h" } -module std_private_concepts_assignable [system] { header "__concepts/assignable.h" } -module std_private_concepts_boolean_testable [system] { header "__concepts/boolean_testable.h" } -module std_private_concepts_class_or_enum [system] { header "__concepts/class_or_enum.h" } -module std_private_concepts_common_reference_with [system] { header "__concepts/common_reference_with.h" } -module std_private_concepts_common_with [system] { header "__concepts/common_with.h" } -module std_private_concepts_constructible [system] { - header "__concepts/constructible.h" - export std_private_concepts_destructible -} -module std_private_concepts_convertible_to [system] { header "__concepts/convertible_to.h" } -module std_private_concepts_copyable [system] { header "__concepts/copyable.h" } -module std_private_concepts_derived_from [system] { header "__concepts/derived_from.h" } -module std_private_concepts_destructible [system] { - header "__concepts/destructible.h" - export std_private_type_traits_is_nothrow_destructible -} -module std_private_concepts_different_from [system] { header "__concepts/different_from.h" } -module std_private_concepts_equality_comparable [system] { - header "__concepts/equality_comparable.h" - export std_private_type_traits_common_reference -} -module std_private_concepts_invocable [system] { header "__concepts/invocable.h" } -module std_private_concepts_movable [system] { - header "__concepts/movable.h" - export std_private_type_traits_is_object -} -module std_private_concepts_predicate [system] { header "__concepts/predicate.h" } -module std_private_concepts_regular [system] { header "__concepts/regular.h" } -module std_private_concepts_relation [system] { header "__concepts/relation.h" } -module std_private_concepts_same_as [system] { - header "__concepts/same_as.h" - export std_private_type_traits_is_same -} -module std_private_concepts_semiregular [system] { header "__concepts/semiregular.h" } -module std_private_concepts_swappable [system] { header "__concepts/swappable.h" } -module std_private_concepts_totally_ordered [system] { header "__concepts/totally_ordered.h" } - -module std_private_condition_variable_condition_variable [system] { - header "__condition_variable/condition_variable.h" - export * -} - -module std_private_coroutine_coroutine_handle [system] { header "__coroutine/coroutine_handle.h" } -module std_private_coroutine_coroutine_traits [system] { header "__coroutine/coroutine_traits.h" } -module std_private_coroutine_noop_coroutine_handle [system] { header "__coroutine/noop_coroutine_handle.h" } -module std_private_coroutine_trivial_awaitables [system] { header "__coroutine/trivial_awaitables.h" } - -module std_private_debug_utils_randomize_range [system] { header "__debug_utils/randomize_range.h" } -module std_private_debug_utils_strict_weak_ordering_check [system] { - header "__debug_utils/strict_weak_ordering_check.h" - export std_private_type_traits_is_constant_evaluated -} - -module std_private_exception_exception [system] { header "__exception/exception.h" } -module std_private_exception_exception_ptr [system] { - header "__exception/exception_ptr.h" - export std_private_exception_operations -} -module std_private_exception_nested_exception [system] { header "__exception/nested_exception.h" } -module std_private_exception_operations [system] { header "__exception/operations.h" } -module std_private_exception_terminate [system] { header "__exception/terminate.h" } - -module std_private_expected_bad_expected_access [system] { header "__expected/bad_expected_access.h" } -module std_private_expected_expected [system] { header "__expected/expected.h" } -module std_private_expected_unexpect [system] { header "__expected/unexpect.h" } -module std_private_expected_unexpected [system] { header "__expected/unexpected.h" } - -module std_private_filesystem_copy_options [system] { header "__filesystem/copy_options.h" } -module std_private_filesystem_directory_entry [system] { - header "__filesystem/directory_entry.h" - export * -} -module std_private_filesystem_directory_iterator [system] { - header "__filesystem/directory_iterator.h" - export * -} -module std_private_filesystem_directory_options [system] { header "__filesystem/directory_options.h" } -module std_private_filesystem_file_status [system] { header "__filesystem/file_status.h" } -module std_private_filesystem_file_time_type [system] { header "__filesystem/file_time_type.h" } -module std_private_filesystem_file_type [system] { header "__filesystem/file_type.h" } -module std_private_filesystem_filesystem_error [system] { - header "__filesystem/filesystem_error.h" - export * -} -module std_private_filesystem_operations [system] { header "__filesystem/operations.h" } -module std_private_filesystem_path [system] { - header "__filesystem/path.h" - export * -} -module std_private_filesystem_path_iterator [system] { header "__filesystem/path_iterator.h" } -module std_private_filesystem_perm_options [system] { header "__filesystem/perm_options.h" } -module std_private_filesystem_perms [system] { header "__filesystem/perms.h" } -module std_private_filesystem_recursive_directory_iterator [system] { - header "__filesystem/recursive_directory_iterator.h" - export * -} -module std_private_filesystem_space_info [system] { header "__filesystem/space_info.h" } -module std_private_filesystem_u8path [system] { header "__filesystem/u8path.h" } - -module std_private_format_buffer [system] { header "__format/buffer.h" } -module std_private_format_concepts [system] { header "__format/concepts.h" } -module std_private_format_container_adaptor [system] { header "__format/container_adaptor.h" } -module std_private_format_enable_insertable [system] { header "__format/enable_insertable.h" } -module std_private_format_escaped_output_table [system] { header "__format/escaped_output_table.h" } -module std_private_format_extended_grapheme_cluster_table [system] { header "__format/extended_grapheme_cluster_table.h" } -module std_private_format_format_arg [system] { header "__format/format_arg.h" } -module std_private_format_format_arg_store [system] { header "__format/format_arg_store.h" } -module std_private_format_format_args [system] { header "__format/format_args.h" } -module std_private_format_format_context [system] { - header "__format/format_context.h" - export * -} -module std_private_format_format_error [system] { header "__format/format_error.h" } -module std_private_format_format_functions [system] { - header "__format/format_functions.h" - export std_string -} -module std_private_format_format_fwd [system] { header "__format/format_fwd.h" } -module std_private_format_format_parse_context [system] { header "__format/format_parse_context.h" } -module std_private_format_format_string [system] { header "__format/format_string.h" } -module std_private_format_format_to_n_result [system] { - header "__format/format_to_n_result.h" - export std_private_iterator_incrementable_traits -} -module std_private_format_formatter [system] { header "__format/formatter.h" } -module std_private_format_formatter_bool [system] { header "__format/formatter_bool.h" } -module std_private_format_formatter_char [system] { header "__format/formatter_char.h" } -module std_private_format_formatter_floating_point [system] { header "__format/formatter_floating_point.h" } -module std_private_format_formatter_integer [system] { header "__format/formatter_integer.h" } -module std_private_format_formatter_integral [system] { header "__format/formatter_integral.h" } -module std_private_format_formatter_output [system] { header "__format/formatter_output.h" } -module std_private_format_formatter_pointer [system] { header "__format/formatter_pointer.h" } -module std_private_format_formatter_string [system] { header "__format/formatter_string.h" } -module std_private_format_formatter_tuple [system] { header "__format/formatter_tuple.h" } -module std_private_format_parser_std_format_spec [system] { header "__format/parser_std_format_spec.h" } -module std_private_format_range_default_formatter [system] { header "__format/range_default_formatter.h" } -module std_private_format_range_formatter [system] { header "__format/range_formatter.h" } -module std_private_format_unicode [system] { - header "__format/unicode.h" - export std_private_format_extended_grapheme_cluster_table -} -module std_private_format_width_estimation_table [system] { header "__format/width_estimation_table.h" } -module std_private_format_write_escaped [system] { header "__format/write_escaped.h" } - -module std_private_functional_binary_function [system] { header "__functional/binary_function.h" } -module std_private_functional_binary_negate [system] { header "__functional/binary_negate.h" } -module std_private_functional_bind [system] { header "__functional/bind.h" } -module std_private_functional_bind_back [system] { header "__functional/bind_back.h" } -module std_private_functional_bind_front [system] { header "__functional/bind_front.h" } -module std_private_functional_binder1st [system] { header "__functional/binder1st.h" } -module std_private_functional_binder2nd [system] { header "__functional/binder2nd.h" } -module std_private_functional_boyer_moore_searcher [system] { - header "__functional/boyer_moore_searcher.h" - export std_private_memory_shared_ptr -} -module std_private_functional_compose [system] { - header "__functional/compose.h" - export std_private_functional_perfect_forward -} -module std_private_functional_default_searcher [system] { header "__functional/default_searcher.h" } -module std_private_functional_function [system] { header "__functional/function.h" } -module std_private_functional_hash [system] { - header "__functional/hash.h" - export std_cstdint - export std_private_type_traits_underlying_type - export std_private_utility_pair -} -module std_private_functional_hash_fwd [system] { header "__fwd/hash.h" } -module std_private_functional_identity [system] { header "__functional/identity.h" } -module std_private_functional_invoke [system] { - header "__functional/invoke.h" - export * -} -module std_private_functional_is_transparent [system] { header "__functional/is_transparent.h" } -module std_private_functional_mem_fn [system] { header "__functional/mem_fn.h" } -module std_private_functional_mem_fun_ref [system] { header "__functional/mem_fun_ref.h" } -module std_private_functional_not_fn [system] { header "__functional/not_fn.h" } -module std_private_functional_operations [system] { header "__functional/operations.h" } -module std_private_functional_perfect_forward [system] { - header "__functional/perfect_forward.h" - export * -} -module std_private_functional_pointer_to_binary_function [system] { header "__functional/pointer_to_binary_function.h" } -module std_private_functional_pointer_to_unary_function [system] { header "__functional/pointer_to_unary_function.h" } -module std_private_functional_ranges_operations [system] { header "__functional/ranges_operations.h" } -module std_private_functional_reference_wrapper [system] { header "__functional/reference_wrapper.h" } -module std_private_functional_unary_function [system] { header "__functional/unary_function.h" } -module std_private_functional_unary_negate [system] { header "__functional/unary_negate.h" } -module std_private_functional_weak_result_type [system] { header "__functional/weak_result_type.h" } - -module std_private_ios_fpos [system] { header "__ios/fpos.h" } - -module std_private_iosfwd_fstream_fwd [system] { header "__fwd/fstream.h" } -module std_private_iosfwd_ios_fwd [system] { header "__fwd/ios.h" } -module std_private_iosfwd_istream_fwd [system] { header "__fwd/istream.h" } -module std_private_iosfwd_ostream_fwd [system] { header "__fwd/ostream.h" } -module std_private_iosfwd_sstream_fwd [system] { header "__fwd/sstream.h" } -module std_private_iosfwd_streambuf_fwd [system] { header "__fwd/streambuf.h" } - -module std_private_iterator_access [system] { header "__iterator/access.h" } -module std_private_iterator_advance [system] { header "__iterator/advance.h" } -module std_private_iterator_back_insert_iterator [system] { header "__iterator/back_insert_iterator.h" } -module std_private_iterator_bounded_iter [system] { header "__iterator/bounded_iter.h" } -module std_private_iterator_common_iterator [system] { header "__iterator/common_iterator.h" } -module std_private_iterator_concepts [system] { - header "__iterator/concepts.h" - export std_private_concepts_constructible - export std_private_concepts_equality_comparable - export std_private_concepts_movable - export std_private_type_traits_common_reference - export std_private_type_traits_is_reference - export std_private_type_traits_remove_cvref -} -module std_private_iterator_counted_iterator [system] { header "__iterator/counted_iterator.h" } -module std_private_iterator_cpp17_iterator_concepts [system] { header "__iterator/cpp17_iterator_concepts.h" } -module std_private_iterator_data [system] { header "__iterator/data.h" } -module std_private_iterator_default_sentinel [system] { header "__iterator/default_sentinel.h" } -module std_private_iterator_distance [system] { - header "__iterator/distance.h" - export std_private_ranges_size -} -module std_private_iterator_empty [system] { header "__iterator/empty.h" } -module std_private_iterator_erase_if_container [system] { header "__iterator/erase_if_container.h" } -module std_private_iterator_front_insert_iterator [system] { header "__iterator/front_insert_iterator.h" } -module std_private_iterator_incrementable_traits [system] { header "__iterator/incrementable_traits.h" } -module std_private_iterator_indirectly_comparable [system] { header "__iterator/indirectly_comparable.h" } -module std_private_iterator_insert_iterator [system] { header "__iterator/insert_iterator.h" } -module std_private_iterator_istream_iterator [system] { header "__iterator/istream_iterator.h" } -module std_private_iterator_istreambuf_iterator [system] { header "__iterator/istreambuf_iterator.h" } -module std_private_iterator_iter_move [system] { header "__iterator/iter_move.h" } -module std_private_iterator_iter_swap [system] { header "__iterator/iter_swap.h" } -module std_private_iterator_iterator [system] { header "__iterator/iterator.h" } -module std_private_iterator_iterator_traits [system] { - header "__iterator/iterator_traits.h" - export std_private_type_traits_is_primary_template -} -module std_private_iterator_iterator_with_data [system] { header "__iterator/iterator_with_data.h" } -module std_private_iterator_mergeable [system] { - header "__iterator/mergeable.h" - export std_private_functional_ranges_operations -} -module std_private_iterator_move_iterator [system] { header "__iterator/move_iterator.h" } -module std_private_iterator_move_sentinel [system] { header "__iterator/move_sentinel.h" } -module std_private_iterator_next [system] { header "__iterator/next.h" } -module std_private_iterator_ostream_iterator [system] { header "__iterator/ostream_iterator.h" } -module std_private_iterator_ostreambuf_iterator [system] { - header "__iterator/ostreambuf_iterator.h" - export * -} -module std_private_iterator_permutable [system] { header "__iterator/permutable.h" } -module std_private_iterator_prev [system] { header "__iterator/prev.h" } -module std_private_iterator_projected [system] { header "__iterator/projected.h" } -module std_private_iterator_ranges_iterator_traits [system] { header "__iterator/ranges_iterator_traits.h" } -module std_private_iterator_readable_traits [system] { header "__iterator/readable_traits.h" } -module std_private_iterator_reverse_access [system] { header "__iterator/reverse_access.h" } -module std_private_iterator_reverse_iterator [system] { header "__iterator/reverse_iterator.h" } -module std_private_iterator_segmented_iterator [system] { header "__iterator/segmented_iterator.h" } -module std_private_iterator_size [system] { header "__iterator/size.h" } -module std_private_iterator_sortable [system] { - header "__iterator/sortable.h" - export std_private_functional_ranges_operations -} -module std_private_iterator_unreachable_sentinel [system] { header "__iterator/unreachable_sentinel.h" } -module std_private_iterator_wrap_iter [system] { header "__iterator/wrap_iter.h" } - -module std_private_locale_locale_base_api_bsd_locale_defaults [system] { textual header "__locale_dir/locale_base_api/bsd_locale_defaults.h" } -module std_private_locale_locale_base_api_bsd_locale_fallbacks [system] { textual header "__locale_dir/locale_base_api/bsd_locale_fallbacks.h" } -module std_private_locale_locale_base_api_locale_guard [system] { header "__locale_dir/locale_base_api/locale_guard.h" } - -module std_private_mdspan_default_accessor [system] { header "__mdspan/default_accessor.h" } -module std_private_mdspan_extents [system] { - header "__mdspan/extents.h" - export * -} -module std_private_mdspan_layout_left [system] { header "__mdspan/layout_left.h" } -module std_private_mdspan_layout_right [system] { header "__mdspan/layout_right.h" } -module std_private_mdspan_mdspan_fwd [system] { header "__fwd/mdspan.h" } - -module std_private_memory_addressof [system] { header "__memory/addressof.h" } -module std_private_memory_align [system] { header "__memory/align.h" } -module std_private_memory_aligned_alloc [system] { header "__memory/aligned_alloc.h" } -module std_private_memory_allocate_at_least [system] { header "__memory/allocate_at_least.h" } -module std_private_memory_allocation_guard [system] { header "__memory/allocation_guard.h" } -module std_private_memory_allocator [system] { header "__memory/allocator.h" } -module std_private_memory_allocator_arg_t [system] { header "__memory/allocator_arg_t.h" } -module std_private_memory_allocator_destructor [system] { header "__memory/allocator_destructor.h" } -module std_private_memory_allocator_traits [system] { header "__memory/allocator_traits.h" } -module std_private_memory_assume_aligned [system] { header "__memory/assume_aligned.h" } -module std_private_memory_auto_ptr [system] { header "__memory/auto_ptr.h" } -module std_private_memory_builtin_new_allocator [system] { header "__memory/builtin_new_allocator.h" } -module std_private_memory_compressed_pair [system] { header "__memory/compressed_pair.h" } -module std_private_memory_concepts [system] { - header "__memory/concepts.h" - export std_private_type_traits_remove_reference -} -module std_private_memory_construct_at [system] { header "__memory/construct_at.h" } -module std_private_memory_destruct_n [system] { header "__memory/destruct_n.h" } -module std_private_memory_pointer_traits [system] { header "__memory/pointer_traits.h" } -module std_private_memory_ranges_construct_at [system] { header "__memory/ranges_construct_at.h" } -module std_private_memory_ranges_uninitialized_algorithms [system] { - header "__memory/ranges_uninitialized_algorithms.h" - export std_private_algorithm_in_out_result -} -module std_private_memory_raw_storage_iterator [system] { header "__memory/raw_storage_iterator.h" } -module std_private_memory_shared_ptr [system] { - header "__memory/shared_ptr.h" - export std_private_memory_uninitialized_algorithms -} -module std_private_memory_swap_allocator [system] { header "__memory/swap_allocator.h" } -module std_private_memory_temp_value [system] { header "__memory/temp_value.h" } -module std_private_memory_temporary_buffer [system] { header "__memory/temporary_buffer.h" } -module std_private_memory_uninitialized_algorithms [system] { - header "__memory/uninitialized_algorithms.h" - export std_private_algorithm_copy -} -module std_private_memory_unique_ptr [system] { - header "__memory/unique_ptr.h" - export std_private_type_traits_add_lvalue_reference - export std_private_type_traits_is_pointer - export std_private_type_traits_type_identity -} -module std_private_memory_uses_allocator [system] { header "__memory/uses_allocator.h" } -module std_private_memory_uses_allocator_construction [system] { header "__memory/uses_allocator_construction.h" } -module std_private_memory_voidify [system] { header "__memory/voidify.h" } - -module std_private_memory_resource_memory_resource [system] { header "__memory_resource/memory_resource.h" } -module std_private_memory_resource_memory_resource_fwd [system] { header "__fwd/memory_resource.h" } -module std_private_memory_resource_monotonic_buffer_resource [system] { header "__memory_resource/monotonic_buffer_resource.h" } -module std_private_memory_resource_polymorphic_allocator [system] { header "__memory_resource/polymorphic_allocator.h" } -module std_private_memory_resource_pool_options [system] { header "__memory_resource/pool_options.h" } -module std_private_memory_resource_synchronized_pool_resource [system] { - header "__memory_resource/synchronized_pool_resource.h" - export * -} -module std_private_memory_resource_unsynchronized_pool_resource [system] { header "__memory_resource/unsynchronized_pool_resource.h" } - -module std_private_mutex_lock_guard [system] { header "__mutex/lock_guard.h" } -module std_private_mutex_mutex [system] { header "__mutex/mutex.h" } -module std_private_mutex_tag_types [system] { header "__mutex/tag_types.h" } -module std_private_mutex_unique_lock [system] { header "__mutex/unique_lock.h" } - -module std_private_numeric_accumulate [system] { header "__numeric/accumulate.h" } -module std_private_numeric_adjacent_difference [system] { header "__numeric/adjacent_difference.h" } -module std_private_numeric_exclusive_scan [system] { header "__numeric/exclusive_scan.h" } -module std_private_numeric_gcd_lcm [system] { header "__numeric/gcd_lcm.h" } -module std_private_numeric_inclusive_scan [system] { header "__numeric/inclusive_scan.h" } -module std_private_numeric_inner_product [system] { header "__numeric/inner_product.h" } -module std_private_numeric_iota [system] { header "__numeric/iota.h" } -module std_private_numeric_midpoint [system] { header "__numeric/midpoint.h" } -module std_private_numeric_partial_sum [system] { header "__numeric/partial_sum.h" } -module std_private_numeric_pstl_reduce [system] { header "__numeric/pstl_reduce.h" } -module std_private_numeric_pstl_transform_reduce [system] { - header "__numeric/pstl_transform_reduce.h" - export * -} -module std_private_numeric_reduce [system] { header "__numeric/reduce.h" } -module std_private_numeric_transform_exclusive_scan [system] { header "__numeric/transform_exclusive_scan.h" } -module std_private_numeric_transform_inclusive_scan [system] { header "__numeric/transform_inclusive_scan.h" } -module std_private_numeric_transform_reduce [system] { header "__numeric/transform_reduce.h" } - -module std_private_random_bernoulli_distribution [system] { header "__random/bernoulli_distribution.h" } -module std_private_random_binomial_distribution [system] { header "__random/binomial_distribution.h" } -module std_private_random_cauchy_distribution [system] { header "__random/cauchy_distribution.h" } -module std_private_random_chi_squared_distribution [system] { header "__random/chi_squared_distribution.h" } -module std_private_random_clamp_to_integral [system] { header "__random/clamp_to_integral.h" } -module std_private_random_default_random_engine [system] { header "__random/default_random_engine.h" } -module std_private_random_discard_block_engine [system] { header "__random/discard_block_engine.h" } -module std_private_random_discrete_distribution [system] { - header "__random/discrete_distribution.h" - export * -} -module std_private_random_exponential_distribution [system] { header "__random/exponential_distribution.h" } -module std_private_random_extreme_value_distribution [system] { header "__random/extreme_value_distribution.h" } -module std_private_random_fisher_f_distribution [system] { header "__random/fisher_f_distribution.h" } -module std_private_random_gamma_distribution [system] { header "__random/gamma_distribution.h" } -module std_private_random_generate_canonical [system] { header "__random/generate_canonical.h" } -module std_private_random_geometric_distribution [system] { header "__random/geometric_distribution.h" } -module std_private_random_independent_bits_engine [system] { header "__random/independent_bits_engine.h" } -module std_private_random_is_seed_sequence [system] { header "__random/is_seed_sequence.h" } -module std_private_random_is_valid [system] { header "__random/is_valid.h" } -module std_private_random_knuth_b [system] { header "__random/knuth_b.h" } -module std_private_random_linear_congruential_engine [system] { header "__random/linear_congruential_engine.h" } -module std_private_random_log2 [system] { header "__random/log2.h" } -module std_private_random_lognormal_distribution [system] { header "__random/lognormal_distribution.h" } -module std_private_random_mersenne_twister_engine [system] { header "__random/mersenne_twister_engine.h" } -module std_private_random_negative_binomial_distribution [system] { header "__random/negative_binomial_distribution.h" } -module std_private_random_normal_distribution [system] { header "__random/normal_distribution.h" } -module std_private_random_piecewise_constant_distribution [system] { - header "__random/piecewise_constant_distribution.h" - export * -} -module std_private_random_piecewise_linear_distribution [system] { - header "__random/piecewise_linear_distribution.h" - export * -} -module std_private_random_poisson_distribution [system] { header "__random/poisson_distribution.h" } -module std_private_random_random_device [system] { header "__random/random_device.h" } -module std_private_random_ranlux [system] { header "__random/ranlux.h" } -module std_private_random_seed_seq [system] { header "__random/seed_seq.h" } -module std_private_random_shuffle_order_engine [system] { header "__random/shuffle_order_engine.h" } -module std_private_random_student_t_distribution [system] { header "__random/student_t_distribution.h" } -module std_private_random_subtract_with_carry_engine [system] { header "__random/subtract_with_carry_engine.h" } -module std_private_random_uniform_int_distribution [system] { header "__random/uniform_int_distribution.h" } -module std_private_random_uniform_random_bit_generator [system] { header "__random/uniform_random_bit_generator.h" } -module std_private_random_uniform_real_distribution [system] { header "__random/uniform_real_distribution.h" } -module std_private_random_weibull_distribution [system] { header "__random/weibull_distribution.h" } - -module std_private_ranges_access [system] { header "__ranges/access.h" } -module std_private_ranges_all [system] { - header "__ranges/all.h" - export std_private_functional_compose - export std_private_functional_perfect_forward - export std_private_ranges_owning_view -} -module std_private_ranges_as_rvalue_view [system] { header "__ranges/as_rvalue_view.h" } -module std_private_ranges_common_view [system] { header "__ranges/common_view.h" } -module std_private_ranges_concepts [system] { - header "__ranges/concepts.h" - export std_private_iterator_concepts -} -module std_private_ranges_container_compatible_range [system] { header "__ranges/container_compatible_range.h" } -module std_private_ranges_counted [system] { - header "__ranges/counted.h" - export std_span -} -module std_private_ranges_dangling [system] { header "__ranges/dangling.h" } -module std_private_ranges_data [system] { header "__ranges/data.h" } -module std_private_ranges_drop_view [system] { header "__ranges/drop_view.h" } -module std_private_ranges_drop_while_view [system] { header "__ranges/drop_while_view.h" } -module std_private_ranges_elements_view [system] { header "__ranges/elements_view.h" } -module std_private_ranges_empty [system] { header "__ranges/empty.h" } -module std_private_ranges_empty_view [system] { header "__ranges/empty_view.h" } -module std_private_ranges_enable_borrowed_range [system] { header "__ranges/enable_borrowed_range.h" } -module std_private_ranges_enable_view [system] { header "__ranges/enable_view.h" } -module std_private_ranges_filter_view [system] { - header "__ranges/filter_view.h" - export std_private_ranges_range_adaptor -} -module std_private_ranges_from_range [system] { header "__ranges/from_range.h" } -module std_private_ranges_iota_view [system] { header "__ranges/iota_view.h" } -module std_private_ranges_istream_view [system] { - @requires_LIBCXX_ENABLE_LOCALIZATION@ - header "__ranges/istream_view.h" -} -module std_private_ranges_join_view [system] { - header "__ranges/join_view.h" - export std_private_iterator_iterator_with_data - export std_private_iterator_segmented_iterator -} -module std_private_ranges_lazy_split_view [system] { - header "__ranges/lazy_split_view.h" - export std_private_ranges_non_propagating_cache -} -module std_private_ranges_movable_box [system] { header "__ranges/movable_box.h" } -module std_private_ranges_non_propagating_cache [system] { header "__ranges/non_propagating_cache.h" } -module std_private_ranges_owning_view [system] { header "__ranges/owning_view.h" } -module std_private_ranges_range_adaptor [system] { header "__ranges/range_adaptor.h" } -module std_private_ranges_rbegin [system] { header "__ranges/rbegin.h" } -module std_private_ranges_ref_view [system] { header "__ranges/ref_view.h" } -module std_private_ranges_rend [system] { header "__ranges/rend.h" } -module std_private_ranges_reverse_view [system] { header "__ranges/reverse_view.h" } -module std_private_ranges_single_view [system] { header "__ranges/single_view.h" } -module std_private_ranges_size [system] { - header "__ranges/size.h" - export std_private_type_traits_make_unsigned -} -module std_private_ranges_split_view [system] { header "__ranges/split_view.h" } -module std_private_ranges_subrange [system] { - header "__ranges/subrange.h" - export std_private_ranges_subrange_fwd -} -module std_private_ranges_subrange_fwd [system] { - header "__fwd/subrange.h" - export std_private_iterator_concepts -} -module std_private_ranges_take_view [system] { header "__ranges/take_view.h" } -module std_private_ranges_take_while_view [system] { header "__ranges/take_while_view.h" } -module std_private_ranges_transform_view [system] { - header "__ranges/transform_view.h" - export std_private_functional_bind_back - export std_private_functional_perfect_forward - export std_private_ranges_movable_box -} -module std_private_ranges_view_interface [system] { header "__ranges/view_interface.h" } -module std_private_ranges_views [system] { header "__ranges/views.h" } -module std_private_ranges_zip_view [system] { header "__ranges/zip_view.h" } - -module std_private_span_span_fwd [system] { header "__fwd/span.h" } - -module std_private_stop_token_atomic_unique_lock [system] { header "__stop_token/atomic_unique_lock.h" } -module std_private_stop_token_intrusive_list_view [system] { header "__stop_token/intrusive_list_view.h" } -module std_private_stop_token_intrusive_shared_ptr [system] { header "__stop_token/intrusive_shared_ptr.h" } -module std_private_stop_token_stop_callback [system] { header "__stop_token/stop_callback.h" } -module std_private_stop_token_stop_source [system] { - header "__stop_token/stop_source.h" - export * -} -module std_private_stop_token_stop_state [system] { - header "__stop_token/stop_state.h" - export * -} -module std_private_stop_token_stop_token [system] { - header "__stop_token/stop_token.h" - export * -} - -module std_private_string_char_traits [system] { header "__string/char_traits.h" } -module std_private_string_constexpr_c_functions [system] { - header "__string/constexpr_c_functions.h" - export std_private_type_traits_is_equality_comparable -} -module std_private_string_extern_template_lists [system] { header "__string/extern_template_lists.h" } -module std_private_string_string_fwd [system] { header "__fwd/string.h" } - -module std_private_string_view_string_view_fwd [system] { header "__fwd/string_view.h" } - -module std_private_system_error_errc [system] { header "__system_error/errc.h" } -module std_private_system_error_error_category [system] { header "__system_error/error_category.h" } -module std_private_system_error_error_code [system] { - header "__system_error/error_code.h" - export std_private_functional_hash - export std_private_functional_unary_function -} -module std_private_system_error_error_condition [system] { - header "__system_error/error_condition.h" - export std_private_functional_hash - export std_private_functional_unary_function -} -module std_private_system_error_system_error [system] { header "__system_error/system_error.h" } - -module std_private_thread_formatter [system] { header "__thread/formatter.h" } -module std_private_thread_id [system] { header "__thread/id.h" } -module std_private_thread_poll_with_backoff [system] { header "__thread/poll_with_backoff.h" } -module std_private_thread_this_thread [system] { header "__thread/this_thread.h" } -module std_private_thread_thread [system] { - header "__thread/thread.h" - export * -} -module std_private_thread_timed_backoff_policy [system] { header "__thread/timed_backoff_policy.h" } - -module std_private_tuple_get_fwd [system] { header "__fwd/get.h" } -module std_private_tuple_make_tuple_types [system] { header "__tuple/make_tuple_types.h" } -module std_private_tuple_pair_like [system] { - header "__tuple/pair_like.h" - export std_private_tuple_tuple_like -} -module std_private_tuple_sfinae_helpers [system] { header "__tuple/sfinae_helpers.h" } -module std_private_tuple_tuple_element [system] { header "__tuple/tuple_element.h" } -module std_private_tuple_tuple_fwd [system] { header "__fwd/tuple.h" } -module std_private_tuple_tuple_indices [system] { header "__tuple/tuple_indices.h" } -module std_private_tuple_tuple_like [system] { header "__tuple/tuple_like.h" } -module std_private_tuple_tuple_like_ext [system] { header "__tuple/tuple_like_ext.h" } -module std_private_tuple_tuple_size [system] { header "__tuple/tuple_size.h" } -module std_private_tuple_tuple_types [system] { header "__tuple/tuple_types.h" } - -module std_private_type_traits_add_const [system] { header "__type_traits/add_const.h" } -module std_private_type_traits_add_cv [system] { header "__type_traits/add_cv.h" } -module std_private_type_traits_add_lvalue_reference [system] { - header "__type_traits/add_lvalue_reference.h" - export std_private_type_traits_is_referenceable -} -module std_private_type_traits_add_pointer [system] { header "__type_traits/add_pointer.h" } -module std_private_type_traits_add_rvalue_reference [system] { header "__type_traits/add_rvalue_reference.h" } -module std_private_type_traits_add_volatile [system] { header "__type_traits/add_volatile.h" } -module std_private_type_traits_aligned_storage [system] { header "__type_traits/aligned_storage.h" } -module std_private_type_traits_aligned_union [system] { header "__type_traits/aligned_union.h" } -module std_private_type_traits_alignment_of [system] { header "__type_traits/alignment_of.h" } -module std_private_type_traits_apply_cv [system] { - header "__type_traits/apply_cv.h" - export std_private_type_traits_is_const - export std_private_type_traits_is_volatile -} -module std_private_type_traits_can_extract_key [system] { header "__type_traits/can_extract_key.h" } -module std_private_type_traits_common_reference [system] { - header "__type_traits/common_reference.h" - export std_private_type_traits_remove_cvref -} -module std_private_type_traits_common_type [system] { - header "__type_traits/common_type.h" - export std_private_utility_declval -} -module std_private_type_traits_conditional [system] { header "__type_traits/conditional.h" } -module std_private_type_traits_conjunction [system] { header "__type_traits/conjunction.h" } -module std_private_type_traits_copy_cv [system] { header "__type_traits/copy_cv.h" } -module std_private_type_traits_copy_cvref [system] { header "__type_traits/copy_cvref.h" } -module std_private_type_traits_datasizeof [system] { header "__type_traits/datasizeof.h" } -module std_private_type_traits_decay [system] { - header "__type_traits/decay.h" - export std_private_type_traits_add_pointer -} -module std_private_type_traits_dependent_type [system] { header "__type_traits/dependent_type.h" } -module std_private_type_traits_disjunction [system] { header "__type_traits/disjunction.h" } -module std_private_type_traits_enable_if [system] { header "__type_traits/enable_if.h" } -module std_private_type_traits_extent [system] { header "__type_traits/extent.h" } -module std_private_type_traits_has_unique_object_representation [system] { header "__type_traits/has_unique_object_representation.h" } -module std_private_type_traits_has_virtual_destructor [system] { header "__type_traits/has_virtual_destructor.h" } -module std_private_type_traits_integral_constant [system] { header "__type_traits/integral_constant.h" } -module std_private_type_traits_invoke [system] { - header "__type_traits/invoke.h" - export std_private_type_traits_conditional - export std_private_type_traits_decay - export std_private_type_traits_decay - export std_private_type_traits_enable_if - export std_private_type_traits_is_base_of - export std_private_type_traits_is_core_convertible - export std_private_type_traits_is_reference_wrapper - export std_private_type_traits_is_same - export std_private_type_traits_is_void - export std_private_type_traits_nat - export std_private_type_traits_remove_cv -} -module std_private_type_traits_is_abstract [system] { header "__type_traits/is_abstract.h" } -module std_private_type_traits_is_aggregate [system] { header "__type_traits/is_aggregate.h" } -module std_private_type_traits_is_allocator [system] { header "__type_traits/is_allocator.h" } -module std_private_type_traits_is_always_bitcastable [system] { header "__type_traits/is_always_bitcastable.h" } -module std_private_type_traits_is_arithmetic [system] { - header "__type_traits/is_arithmetic.h" - export std_private_type_traits_integral_constant -} -module std_private_type_traits_is_array [system] { - header "__type_traits/is_array.h" - export std_private_type_traits_integral_constant -} -module std_private_type_traits_is_assignable [system] { header "__type_traits/is_assignable.h" } -module std_private_type_traits_is_base_of [system] { header "__type_traits/is_base_of.h" } -module std_private_type_traits_is_bounded_array [system] { header "__type_traits/is_bounded_array.h" } -module std_private_type_traits_is_callable [system] { header "__type_traits/is_callable.h" } -module std_private_type_traits_is_char_like_type [system] { header "__type_traits/is_char_like_type.h" } -module std_private_type_traits_is_class [system] { header "__type_traits/is_class.h" } -module std_private_type_traits_is_compound [system] { header "__type_traits/is_compound.h" } -module std_private_type_traits_is_const [system] { header "__type_traits/is_const.h" } -module std_private_type_traits_is_constant_evaluated [system] { header "__type_traits/is_constant_evaluated.h" } -module std_private_type_traits_is_constructible [system] { header "__type_traits/is_constructible.h" } -module std_private_type_traits_is_convertible [system] { - header "__type_traits/is_convertible.h" - export std_private_type_traits_is_array -} -module std_private_type_traits_is_copy_assignable [system] { header "__type_traits/is_copy_assignable.h" } -module std_private_type_traits_is_copy_constructible [system] { header "__type_traits/is_copy_constructible.h" } -module std_private_type_traits_is_core_convertible [system] { - header "__type_traits/is_core_convertible.h" - export std_private_type_traits_integral_constant -} -module std_private_type_traits_is_default_constructible [system] { header "__type_traits/is_default_constructible.h" } -module std_private_type_traits_is_destructible [system] { header "__type_traits/is_destructible.h" } -module std_private_type_traits_is_empty [system] { header "__type_traits/is_empty.h" } -module std_private_type_traits_is_enum [system] { - header "__type_traits/is_enum.h" - export std_private_type_traits_integral_constant -} -module std_private_type_traits_is_equality_comparable [system] { - header "__type_traits/is_equality_comparable.h" - export std_private_type_traits_integral_constant -} -module std_private_type_traits_is_execution_policy [system] { - header "__type_traits/is_execution_policy.h" - export std_private_type_traits_remove_cvref -} -module std_private_type_traits_is_final [system] { header "__type_traits/is_final.h" } -module std_private_type_traits_is_floating_point [system] { header "__type_traits/is_floating_point.h" } -module std_private_type_traits_is_function [system] { header "__type_traits/is_function.h" } -module std_private_type_traits_is_fundamental [system] { header "__type_traits/is_fundamental.h" } -module std_private_type_traits_is_implicitly_default_constructible [system] { header "__type_traits/is_implicitly_default_constructible.h" } -module std_private_type_traits_is_integral [system] { header "__type_traits/is_integral.h" } -module std_private_type_traits_is_literal_type [system] { header "__type_traits/is_literal_type.h" } -module std_private_type_traits_is_member_function_pointer [system] { header "__type_traits/is_member_function_pointer.h" } -module std_private_type_traits_is_member_object_pointer [system] { header "__type_traits/is_member_object_pointer.h" } -module std_private_type_traits_is_member_pointer [system] { header "__type_traits/is_member_pointer.h" } -module std_private_type_traits_is_move_assignable [system] { header "__type_traits/is_move_assignable.h" } -module std_private_type_traits_is_move_constructible [system] { header "__type_traits/is_move_constructible.h" } -module std_private_type_traits_is_nothrow_assignable [system] { header "__type_traits/is_nothrow_assignable.h" } -module std_private_type_traits_is_nothrow_constructible [system] { header "__type_traits/is_nothrow_constructible.h" } -module std_private_type_traits_is_nothrow_convertible [system] { header "__type_traits/is_nothrow_convertible.h" } -module std_private_type_traits_is_nothrow_copy_assignable [system] { header "__type_traits/is_nothrow_copy_assignable.h" } -module std_private_type_traits_is_nothrow_copy_constructible [system] { header "__type_traits/is_nothrow_copy_constructible.h" } -module std_private_type_traits_is_nothrow_default_constructible [system] { header "__type_traits/is_nothrow_default_constructible.h" } -module std_private_type_traits_is_nothrow_destructible [system] { - header "__type_traits/is_nothrow_destructible.h" - export std_private_type_traits_is_destructible -} -module std_private_type_traits_is_nothrow_move_assignable [system] { header "__type_traits/is_nothrow_move_assignable.h" } -module std_private_type_traits_is_nothrow_move_constructible [system] { - header "__type_traits/is_nothrow_move_constructible.h" - export std_private_type_traits_is_nothrow_constructible -} -module std_private_type_traits_is_null_pointer [system] { - header "__type_traits/is_null_pointer.h" - export std_cstddef -} -module std_private_type_traits_is_object [system] { - header "__type_traits/is_object.h" - export std_private_type_traits_is_scalar -} -module std_private_type_traits_is_pod [system] { header "__type_traits/is_pod.h" } -module std_private_type_traits_is_pointer [system] { header "__type_traits/is_pointer.h" } -module std_private_type_traits_is_polymorphic [system] { header "__type_traits/is_polymorphic.h" } -module std_private_type_traits_is_primary_template [system] { - header "__type_traits/is_primary_template.h" - export std_private_type_traits_enable_if -} -module std_private_type_traits_is_reference [system] { header "__type_traits/is_reference.h" } -module std_private_type_traits_is_reference_wrapper [system] { header "__type_traits/is_reference_wrapper.h" } -module std_private_type_traits_is_referenceable [system] { header "__type_traits/is_referenceable.h" } -module std_private_type_traits_is_same [system] { - header "__type_traits/is_same.h" - export std_private_type_traits_integral_constant -} -module std_private_type_traits_is_scalar [system] { - header "__type_traits/is_scalar.h" - export std_private_type_traits_is_null_pointer -} -module std_private_type_traits_is_scoped_enum [system] { header "__type_traits/is_scoped_enum.h" } -module std_private_type_traits_is_signed [system] { header "__type_traits/is_signed.h" } -module std_private_type_traits_is_signed_integer [system] { header "__type_traits/is_signed_integer.h" } -module std_private_type_traits_is_specialization [system] { header "__type_traits/is_specialization.h" } -module std_private_type_traits_is_standard_layout [system] { header "__type_traits/is_standard_layout.h" } -module std_private_type_traits_is_swappable [system] { - header "__type_traits/is_swappable.h" - export std_private_type_traits_is_move_constructible -} -module std_private_type_traits_is_trivial [system] { header "__type_traits/is_trivial.h" } -module std_private_type_traits_is_trivially_assignable [system] { header "__type_traits/is_trivially_assignable.h" } -module std_private_type_traits_is_trivially_constructible [system] { header "__type_traits/is_trivially_constructible.h" } -module std_private_type_traits_is_trivially_copy_assignable [system] { header "__type_traits/is_trivially_copy_assignable.h" } -module std_private_type_traits_is_trivially_copy_constructible [system] { header "__type_traits/is_trivially_copy_constructible.h" } -module std_private_type_traits_is_trivially_copyable [system] { header "__type_traits/is_trivially_copyable.h" } -module std_private_type_traits_is_trivially_default_constructible [system] { header "__type_traits/is_trivially_default_constructible.h" } -module std_private_type_traits_is_trivially_destructible [system] { header "__type_traits/is_trivially_destructible.h" } -module std_private_type_traits_is_trivially_lexicographically_comparable [system] { header "__type_traits/is_trivially_lexicographically_comparable.h" } -module std_private_type_traits_is_trivially_move_assignable [system] { header "__type_traits/is_trivially_move_assignable.h" } -module std_private_type_traits_is_trivially_move_constructible [system] { header "__type_traits/is_trivially_move_constructible.h" } -module std_private_type_traits_is_unbounded_array [system] { header "__type_traits/is_unbounded_array.h" } -module std_private_type_traits_is_union [system] { header "__type_traits/is_union.h" } -module std_private_type_traits_is_unsigned [system] { header "__type_traits/is_unsigned.h" } -module std_private_type_traits_is_unsigned_integer [system] { header "__type_traits/is_unsigned_integer.h" } -module std_private_type_traits_is_valid_expansion [system] { header "__type_traits/is_valid_expansion.h" } -module std_private_type_traits_is_void [system] { - header "__type_traits/is_void.h" - export std_private_type_traits_integral_constant -} -module std_private_type_traits_is_volatile [system] { header "__type_traits/is_volatile.h" } -module std_private_type_traits_lazy [system] { header "__type_traits/lazy.h" } -module std_private_type_traits_make_32_64_or_128_bit [system] { header "__type_traits/make_32_64_or_128_bit.h" } -module std_private_type_traits_make_const_lvalue_ref [system] { header "__type_traits/make_const_lvalue_ref.h" } -module std_private_type_traits_make_signed [system] { header "__type_traits/make_signed.h" } -module std_private_type_traits_make_unsigned [system] { - header "__type_traits/make_unsigned.h" - export std_private_type_traits_is_unsigned -} -module std_private_type_traits_maybe_const [system] { header "__type_traits/maybe_const.h" } -module std_private_type_traits_nat [system] { header "__type_traits/nat.h" } -module std_private_type_traits_negation [system] { header "__type_traits/negation.h" } -module std_private_type_traits_noexcept_move_assign_container [system] { header "__type_traits/noexcept_move_assign_container.h" } -module std_private_type_traits_operation_traits [system] { header "__type_traits/operation_traits.h" } -module std_private_type_traits_predicate_traits [system] { header "__type_traits/predicate_traits.h" } -module std_private_type_traits_promote [system] { header "__type_traits/promote.h" } -module std_private_type_traits_rank [system] { header "__type_traits/rank.h" } -module std_private_type_traits_remove_all_extents [system] { header "__type_traits/remove_all_extents.h" } -module std_private_type_traits_remove_const [system] { header "__type_traits/remove_const.h" } -module std_private_type_traits_remove_const_ref [system] { header "__type_traits/remove_const_ref.h" } -module std_private_type_traits_remove_cv [system] { - header "__type_traits/remove_cv.h" - export std_private_type_traits_remove_const - export std_private_type_traits_remove_volatile -} -module std_private_type_traits_remove_cvref [system] { header "__type_traits/remove_cvref.h" } -module std_private_type_traits_remove_extent [system] { header "__type_traits/remove_extent.h" } -module std_private_type_traits_remove_pointer [system] { header "__type_traits/remove_pointer.h" } -module std_private_type_traits_remove_reference [system] { header "__type_traits/remove_reference.h" } -module std_private_type_traits_remove_volatile [system] { header "__type_traits/remove_volatile.h" } -module std_private_type_traits_result_of [system] { header "__type_traits/result_of.h" } -module std_private_type_traits_strip_signature [system] { header "__type_traits/strip_signature.h" } -module std_private_type_traits_type_identity [system] { header "__type_traits/type_identity.h" } -module std_private_type_traits_type_list [system] { header "__type_traits/type_list.h" } -module std_private_type_traits_underlying_type [system] { - header "__type_traits/underlying_type.h" - export std_private_type_traits_is_enum -} -module std_private_type_traits_unwrap_ref [system] { header "__type_traits/unwrap_ref.h" } -module std_private_type_traits_void_t [system] { header "__type_traits/void_t.h" } - -module std_private_utility_as_const [system] { header "__utility/as_const.h" } -module std_private_utility_auto_cast [system] { - header "__utility/auto_cast.h" - export std_private_type_traits_decay -} -module std_private_utility_cmp [system] { - header "__utility/cmp.h" - export std_private_type_traits_make_unsigned -} -module std_private_utility_convert_to_integral [system] { header "__utility/convert_to_integral.h" } -module std_private_utility_declval [system] { header "__utility/declval.h" } -module std_private_utility_exception_guard [system] { header "__utility/exception_guard.h" } -module std_private_utility_exchange [system] { header "__utility/exchange.h" } -module std_private_utility_forward [system] { header "__utility/forward.h" } -module std_private_utility_forward_like [system] { header "__utility/forward_like.h" } -module std_private_utility_in_place [system] { header "__utility/in_place.h" } -module std_private_utility_integer_sequence [system] { header "__utility/integer_sequence.h" } -module std_private_utility_is_pointer_in_range [system] { header "__utility/is_pointer_in_range.h" } -module std_private_utility_move [system] { - header "__utility/move.h" - export std_private_type_traits_is_copy_constructible - export std_private_type_traits_is_nothrow_move_constructible - export std_private_type_traits_remove_reference -} -module std_private_utility_pair [system] { - header "__utility/pair.h" - export std_private_ranges_subrange_fwd - export std_private_tuple_pair_like - export std_private_type_traits_is_assignable - export std_private_type_traits_is_constructible - export std_private_type_traits_is_convertible - export std_private_type_traits_is_copy_assignable - export std_private_type_traits_is_move_assignable - export std_private_type_traits_is_nothrow_copy_constructible - export std_private_type_traits_is_nothrow_default_constructible - export std_private_type_traits_is_nothrow_move_assignable - export std_private_utility_pair_fwd -} -module std_private_utility_pair_fwd [system] { header "__fwd/pair.h" } -module std_private_utility_piecewise_construct [system] { header "__utility/piecewise_construct.h" } -module std_private_utility_priority_tag [system] { header "__utility/priority_tag.h" } -module std_private_utility_rel_ops [system] { header "__utility/rel_ops.h" } -module std_private_utility_swap [system] { - header "__utility/swap.h" - export std_private_type_traits_is_swappable -} -module std_private_utility_terminate_on_exception [system] { header "__utility/terminate_on_exception.h" } -module std_private_utility_to_underlying [system] { header "__utility/to_underlying.h" } -module std_private_utility_unreachable [system] { header "__utility/unreachable.h" } - -module std_private_variant_monostate [system] { header "__variant/monostate.h" } diff --git a/libcxx/test/libcxx/lint/lint_headers.sh.py b/libcxx/test/libcxx/lint/lint_headers.sh.py --- a/libcxx/test/libcxx/lint/lint_headers.sh.py +++ b/libcxx/test/libcxx/lint/lint_headers.sh.py @@ -10,7 +10,9 @@ def exclude_from_consideration(path): return ( - path.endswith(".txt") + path.endswith(".py") + or path.endswith(".txt") + or path.endswith(".json.in") or path.endswith(".modulemap.in") or os.path.basename(path) == "__config" or os.path.basename(path) == "__config_site.in" diff --git a/libcxx/test/libcxx/strings/char.traits/char.traits.specializations/arbitrary_char_type.deprecated.verify.cpp b/libcxx/test/libcxx/strings/char.traits/char.traits.specializations/arbitrary_char_type.deprecated.verify.cpp --- a/libcxx/test/libcxx/strings/char.traits/char.traits.specializations/arbitrary_char_type.deprecated.verify.cpp +++ b/libcxx/test/libcxx/strings/char.traits/char.traits.specializations/arbitrary_char_type.deprecated.verify.cpp @@ -6,6 +6,12 @@ // //===----------------------------------------------------------------------===// +// This should work for modules too, but clang doesn't emit the diagnostics for unknown reasons. +// XFAIL: modules-build && clang-16 +// XFAIL: modules-build && clang-17 +// XFAIL: modules-build && apple-clang-14 +// XFAIL: modules-build && apple-clang-15 + // // template<> struct char_traits for arbitrary T diff --git a/libcxx/utils/libcxx/test/header_information.py b/libcxx/utils/libcxx/test/header_information.py --- a/libcxx/utils/libcxx/test/header_information.py +++ b/libcxx/utils/libcxx/test/header_information.py @@ -132,7 +132,9 @@ return ( not file.is_dir() and not file.name == "module.modulemap.in" + and not file.name == "internal_module_attributes.json.in" and not file.name == "CMakeLists.txt" + and not file.name == "generate_module_map.py" and file.name != "libcxx.imp" )