mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-07-21 10:00:30 +00:00
Release Cosmopolitan v3.6.0
This release is an atomic upgrade to GCC 14.1.0 with C23 and C++23
This commit is contained in:
parent
62ace3623a
commit
5660ec4741
1585 changed files with 117353 additions and 271644 deletions
111
third_party/libcxx/format
vendored
111
third_party/libcxx/format
vendored
|
@ -31,6 +31,7 @@ namespace std {
|
|||
|
||||
public:
|
||||
template<class T> consteval basic_format_string(const T& s);
|
||||
basic_format_string(runtime-format-string<charT> s) noexcept : str(s.str) {} // since C++26
|
||||
|
||||
constexpr basic_string_view<charT> get() const noexcept { return str; }
|
||||
};
|
||||
|
@ -41,6 +42,24 @@ namespace std {
|
|||
using wformat_string = // since C++23, exposition only before C++23
|
||||
basic_format_string<wchar_t, type_identity_t<Args>...>;
|
||||
|
||||
template<class charT> struct runtime-format-string { // since C++26, exposition-only
|
||||
private:
|
||||
basic_string_view<charT> str; // exposition-only
|
||||
|
||||
public:
|
||||
runtime-format-string(basic_string_view<charT> s) noexcept : str(s) {}
|
||||
|
||||
runtime-format-string(const runtime-format-string&) = delete;
|
||||
runtime-format-string& operator=(const runtime-format-string&) = delete;
|
||||
};
|
||||
|
||||
runtime-format-string<char> runtime_format(string_view fmt) noexcept {
|
||||
return fmt;
|
||||
}
|
||||
runtime-format-string<wchar_t> runtime_format(wstring_view fmt) noexcept {
|
||||
return fmt;
|
||||
}
|
||||
|
||||
// [format.functions], formatting functions
|
||||
template<class... Args>
|
||||
string format(format-string<Args...> fmt, Args&&... args);
|
||||
|
@ -151,17 +170,17 @@ namespace std {
|
|||
template<class Context> class basic_format_arg;
|
||||
|
||||
template<class Visitor, class Context>
|
||||
see below visit_format_arg(Visitor&& vis, basic_format_arg<Context> arg);
|
||||
see below visit_format_arg(Visitor&& vis, basic_format_arg<Context> arg); // Deprecated in C++26
|
||||
|
||||
// [format.arg.store], class template format-arg-store
|
||||
template<class Context, class... Args> struct format-arg-store; // exposition only
|
||||
|
||||
template<class Context = format_context, class... Args>
|
||||
format-arg-store<Context, Args...>
|
||||
make_format_args(Args&&... args);
|
||||
make_format_args(Args&... args);
|
||||
template<class... Args>
|
||||
format-arg-store<wformat_context, Args...>
|
||||
make_wformat_args(Args&&... args);
|
||||
make_wformat_args(Args&... args);
|
||||
|
||||
// [format.error], class format_error
|
||||
class format_error;
|
||||
|
@ -169,38 +188,70 @@ namespace std {
|
|||
|
||||
*/
|
||||
|
||||
#include <__assert> // all public C++ headers provide the assertion handler
|
||||
#include <__config>
|
||||
#include <__format/buffer.h>
|
||||
#include <__format/concepts.h>
|
||||
#include <__format/container_adaptor.h>
|
||||
#include <__format/enable_insertable.h>
|
||||
#include <__format/format_arg.h>
|
||||
#include <__format/format_arg_store.h>
|
||||
#include <__format/format_args.h>
|
||||
#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>
|
||||
#include <__format/formatter.h>
|
||||
#include <__format/formatter_bool.h>
|
||||
#include <__format/formatter_char.h>
|
||||
#include <__format/formatter_floating_point.h>
|
||||
#include <__format/formatter_integer.h>
|
||||
#include <__format/formatter_pointer.h>
|
||||
#include <__format/formatter_string.h>
|
||||
#include <__format/formatter_tuple.h>
|
||||
#include <__format/parser_std_format_spec.h>
|
||||
#include <__format/range_default_formatter.h>
|
||||
#include <__format/range_formatter.h>
|
||||
#include <__format/unicode.h>
|
||||
|
||||
#if _LIBCPP_STD_VER >= 20
|
||||
# include <__format/buffer.h>
|
||||
# include <__format/concepts.h>
|
||||
# include <__format/container_adaptor.h>
|
||||
# include <__format/enable_insertable.h>
|
||||
# include <__format/escaped_output_table.h>
|
||||
# include <__format/extended_grapheme_cluster_table.h>
|
||||
# include <__format/format_arg.h>
|
||||
# include <__format/format_arg_store.h>
|
||||
# include <__format/format_args.h>
|
||||
# include <__format/format_context.h>
|
||||
# include <__format/format_error.h>
|
||||
# include <__format/format_functions.h>
|
||||
# include <__format/format_parse_context.h>
|
||||
# include <__format/format_string.h>
|
||||
# include <__format/format_to_n_result.h>
|
||||
# include <__format/formatter.h>
|
||||
# include <__format/formatter_bool.h>
|
||||
# include <__format/formatter_char.h>
|
||||
# include <__format/formatter_floating_point.h>
|
||||
# include <__format/formatter_integer.h>
|
||||
# include <__format/formatter_pointer.h>
|
||||
# include <__format/formatter_string.h>
|
||||
# include <__format/formatter_tuple.h>
|
||||
# include <__format/parser_std_format_spec.h>
|
||||
# include <__format/range_default_formatter.h>
|
||||
# include <__format/range_formatter.h>
|
||||
# include <__format/unicode.h>
|
||||
# include <__fwd/format.h>
|
||||
#endif
|
||||
|
||||
#include <version>
|
||||
|
||||
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
|
||||
# pragma GCC system_header
|
||||
#endif
|
||||
|
||||
#if !defined(_LIBCPP_REMOVE_TRANSITIVE_INCLUDES) && _LIBCPP_STD_VER <= 20
|
||||
# include <array>
|
||||
# include <cctype>
|
||||
# include <cerrno>
|
||||
# include <clocale>
|
||||
# include <cmath>
|
||||
# include <cstddef>
|
||||
# include <cstdint>
|
||||
# include <cstdlib>
|
||||
# include <cstring>
|
||||
# include <cwchar>
|
||||
# include <initializer_list>
|
||||
# include <limits>
|
||||
# include <new>
|
||||
# include <optional>
|
||||
# include <stdexcept>
|
||||
# include <string>
|
||||
# include <string_view>
|
||||
# include <tuple>
|
||||
#endif
|
||||
|
||||
#if !defined(_LIBCPP_REMOVE_TRANSITIVE_INCLUDES) && _LIBCPP_STD_VER <= 20
|
||||
# include <locale>
|
||||
# include <queue>
|
||||
# include <stack>
|
||||
#endif
|
||||
|
||||
#endif // _LIBCPP_FORMAT
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue