[libcxx-commits] [libcxx] 0876668 - [libc++][NFC] Move __format/format_fwd.h to __fwd/format.h (#84336)
via libcxx-commits
libcxx-commits at lists.llvm.org
Fri Mar 8 11:43:15 PST 2024
Author: Nikolas Klauser
Date: 2024-03-08T20:43:10+01:00
New Revision: 087666811452e1b6490d59572337aaa907f93e7c
URL: https://github.com/llvm/llvm-project/commit/087666811452e1b6490d59572337aaa907f93e7c
DIFF: https://github.com/llvm/llvm-project/commit/087666811452e1b6490d59572337aaa907f93e7c.diff
LOG: [libc++][NFC] Move __format/format_fwd.h to __fwd/format.h (#84336)
Added:
libcxx/include/__fwd/format.h
Modified:
libcxx/include/CMakeLists.txt
libcxx/include/__format/concepts.h
libcxx/include/__format/format_arg.h
libcxx/include/__format/format_args.h
libcxx/include/__format/format_context.h
libcxx/include/__format/formatter.h
libcxx/include/format
libcxx/include/libcxx.imp
libcxx/include/module.modulemap
Removed:
libcxx/include/__format/format_fwd.h
################################################################################
diff --git a/libcxx/include/CMakeLists.txt b/libcxx/include/CMakeLists.txt
index 3ea3360186dc56..e37c4ac4fddd8c 100644
--- a/libcxx/include/CMakeLists.txt
+++ b/libcxx/include/CMakeLists.txt
@@ -380,7 +380,6 @@ set(files
__format/format_context.h
__format/format_error.h
__format/format_functions.h
- __format/format_fwd.h
__format/format_parse_context.h
__format/format_string.h
__format/format_to_n_result.h
@@ -430,6 +429,7 @@ set(files
__fwd/array.h
__fwd/bit_reference.h
__fwd/complex.h
+ __fwd/format.h
__fwd/fstream.h
__fwd/functional.h
__fwd/ios.h
diff --git a/libcxx/include/__format/concepts.h b/libcxx/include/__format/concepts.h
index 299c5f40ee35b4..d7b5a9d16df70a 100644
--- a/libcxx/include/__format/concepts.h
+++ b/libcxx/include/__format/concepts.h
@@ -13,8 +13,8 @@
#include <__concepts/same_as.h>
#include <__concepts/semiregular.h>
#include <__config>
-#include <__format/format_fwd.h>
#include <__format/format_parse_context.h>
+#include <__fwd/format.h>
#include <__type_traits/is_specialization.h>
#include <__type_traits/remove_const.h>
#include <__utility/pair.h>
diff --git a/libcxx/include/__format/format_arg.h b/libcxx/include/__format/format_arg.h
index b786ac3b3620e3..4924e5fb325336 100644
--- a/libcxx/include/__format/format_arg.h
+++ b/libcxx/include/__format/format_arg.h
@@ -14,9 +14,9 @@
#include <__concepts/arithmetic.h>
#include <__config>
#include <__format/concepts.h>
-#include <__format/format_fwd.h>
#include <__format/format_parse_context.h>
#include <__functional/invoke.h>
+#include <__fwd/format.h>
#include <__memory/addressof.h>
#include <__type_traits/conditional.h>
#include <__utility/forward.h>
diff --git a/libcxx/include/__format/format_args.h b/libcxx/include/__format/format_args.h
index 9e0afecc0ae967..79fe51f96c6a50 100644
--- a/libcxx/include/__format/format_args.h
+++ b/libcxx/include/__format/format_args.h
@@ -14,7 +14,7 @@
#include <__config>
#include <__format/format_arg.h>
#include <__format/format_arg_store.h>
-#include <__format/format_fwd.h>
+#include <__fwd/format.h>
#include <cstddef>
#include <cstdint>
diff --git a/libcxx/include/__format/format_context.h b/libcxx/include/__format/format_context.h
index 68dcdb49d3aae6..d131e942aca60b 100644
--- a/libcxx/include/__format/format_context.h
+++ b/libcxx/include/__format/format_context.h
@@ -18,7 +18,7 @@
#include <__format/format_arg_store.h>
#include <__format/format_args.h>
#include <__format/format_error.h>
-#include <__format/format_fwd.h>
+#include <__fwd/format.h>
#include <__iterator/back_insert_iterator.h>
#include <__iterator/concepts.h>
#include <__memory/addressof.h>
diff --git a/libcxx/include/__format/formatter.h b/libcxx/include/__format/formatter.h
index 079befc5bd9ca6..47e35789b8175b 100644
--- a/libcxx/include/__format/formatter.h
+++ b/libcxx/include/__format/formatter.h
@@ -12,7 +12,7 @@
#include <__availability>
#include <__config>
-#include <__format/format_fwd.h>
+#include <__fwd/format.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
# pragma GCC system_header
diff --git a/libcxx/include/__format/format_fwd.h b/libcxx/include/__fwd/format.h
similarity index 89%
rename from libcxx/include/__format/format_fwd.h
rename to libcxx/include/__fwd/format.h
index 120b2fc8d47de8..6f5c71243711fe 100644
--- a/libcxx/include/__format/format_fwd.h
+++ b/libcxx/include/__fwd/format.h
@@ -7,8 +7,8 @@
//
//===----------------------------------------------------------------------===//
-#ifndef _LIBCPP___FORMAT_FORMAT_FWD_H
-#define _LIBCPP___FORMAT_FORMAT_FWD_H
+#ifndef _LIBCPP___FWD_FORMAT_H
+#define _LIBCPP___FWD_FORMAT_H
#include <__availability>
#include <__config>
@@ -36,4 +36,4 @@ struct _LIBCPP_TEMPLATE_VIS formatter;
_LIBCPP_END_NAMESPACE_STD
-#endif // _LIBCPP___FORMAT_FORMAT_FWD_H
+#endif // _LIBCPP___FWD_FORMAT_H
diff --git a/libcxx/include/format b/libcxx/include/format
index b2fe0053b974bb..c0485c5a103596 100644
--- a/libcxx/include/format
+++ b/libcxx/include/format
@@ -199,7 +199,6 @@ namespace std {
#include <__format/format_context.h>
#include <__format/format_error.h>
#include <__format/format_functions.h>
-#include <__format/format_fwd.h>
#include <__format/format_parse_context.h>
#include <__format/format_string.h>
#include <__format/format_to_n_result.h>
@@ -215,6 +214,7 @@ namespace std {
#include <__format/range_default_formatter.h>
#include <__format/range_formatter.h>
#include <__format/unicode.h>
+#include <__fwd/format.h>
#include <version>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
diff --git a/libcxx/include/libcxx.imp b/libcxx/include/libcxx.imp
index cdbb0a63fc0eae..e02dc8da6ba182 100644
--- a/libcxx/include/libcxx.imp
+++ b/libcxx/include/libcxx.imp
@@ -374,7 +374,6 @@
{ include: [ "<__format/format_context.h>", "private", "<format>", "public" ] },
{ include: [ "<__format/format_error.h>", "private", "<format>", "public" ] },
{ include: [ "<__format/format_functions.h>", "private", "<format>", "public" ] },
- { include: [ "<__format/format_fwd.h>", "private", "<format>", "public" ] },
{ include: [ "<__format/format_parse_context.h>", "private", "<format>", "public" ] },
{ include: [ "<__format/format_string.h>", "private", "<format>", "public" ] },
{ include: [ "<__format/format_to_n_result.h>", "private", "<format>", "public" ] },
@@ -425,6 +424,7 @@
{ include: [ "<__fwd/bit_reference.h>", "private", "<bitset>", "public" ] },
{ include: [ "<__fwd/bit_reference.h>", "private", "<vector>", "public" ] },
{ include: [ "<__fwd/complex.h>", "private", "<complex>", "public" ] },
+ { include: [ "<__fwd/format.h>", "private", "<format>", "public" ] },
{ include: [ "<__fwd/fstream.h>", "private", "<iosfwd>", "public" ] },
{ include: [ "<__fwd/functional.h>", "private", "<functional>", "public" ] },
{ include: [ "<__fwd/ios.h>", "private", "<iosfwd>", "public" ] },
diff --git a/libcxx/include/module.modulemap b/libcxx/include/module.modulemap
index b247f97c1804d9..98890e890cdb13 100644
--- a/libcxx/include/module.modulemap
+++ b/libcxx/include/module.modulemap
@@ -1315,7 +1315,7 @@ 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_fwd [system] { header "__fwd/format.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] {
More information about the libcxx-commits
mailing list