29#if FMT_GCC_VERSION && FMT_GCC_VERSION < 409
34template <
typename... Args>
39template <>
struct is_char<wchar_t> : std::true_type {};
41template <>
struct is_char<char16_t> : std::true_type {};
42template <>
struct is_char<char32_t> : std::true_type {};
44template <
typename... Args>
46 const Args&... args) {
51#if FMT_USE_USER_DEFINED_LITERALS && !FMT_USE_NONTYPE_TEMPLATE_ARGS
52constexpr detail::udl_arg<wchar_t>
operator"" _a(
const wchar_t* s,
size_t) {
58template <
typename It,
typename Sentinel>
61 return {begin,
end, sep};
64template <
typename Range>
77template <
typename Char, FMT_ENABLE_IF(!std::is_same<Char,
char>::value)>
80 -> std::basic_string<Char> {
86template <
typename... T>
93template <
typename S,
typename... Args,
typename Char =
char_t<S>,
95 !std::is_same<Char, wchar_t>::value)>
96auto format(
const S& format_str, Args&&... args) -> std::basic_string<Char> {
101template <
typename Locale,
typename S,
typename Char =
char_t<S>,
102 FMT_ENABLE_IF(detail::is_locale<Locale>::value&&
103 detail::is_exotic_
char<Char>::value)>
105 const Locale& loc,
const S& format_str,
107 -> std::basic_string<Char> {
111template <
typename Locale,
typename S,
typename... Args,
115inline auto format(
const Locale& loc,
const S& format_str, Args&&... args)
116 -> std::basic_string<Char> {
121template <
typename OutputIt,
typename S,
typename Char =
char_t<S>,
122 FMT_ENABLE_IF(detail::is_output_iterator<OutputIt, Char>::value&&
123 detail::is_exotic_
char<Char>::value)>
127 auto&& buf = detail::get_buffer<Char>(out);
132template <
typename OutputIt,
typename S,
typename... Args,
134 FMT_ENABLE_IF(detail::is_output_iterator<OutputIt, Char>::value&&
136inline auto format_to(OutputIt out,
const S& fmt, Args&&... args) -> OutputIt {
141template <
typename Locale,
typename S,
typename OutputIt,
typename... Args,
143 FMT_ENABLE_IF(detail::is_output_iterator<OutputIt, Char>::value&&
144 detail::is_locale<Locale>::value&&
147 OutputIt out,
const Locale& loc,
const S& format_str,
149 auto&& buf = detail::get_buffer<Char>(out);
151 detail::locale_ref(loc));
156 typename OutputIt,
typename Locale,
typename S,
typename... Args,
158 bool enable = detail::is_output_iterator<OutputIt, Char>::value&&
160inline auto format_to(OutputIt out,
const Locale& loc,
const S& format_str,
167template <
typename OutputIt,
typename Char,
typename... Args,
168 FMT_ENABLE_IF(detail::is_output_iterator<OutputIt, Char>::value&&
174 detail::iterator_buffer<OutputIt, Char, detail::fixed_buffer_traits> buf(out,
177 return {buf.out(), buf.count()};
180template <
typename OutputIt,
typename S,
typename... Args,
182 FMT_ENABLE_IF(detail::is_output_iterator<OutputIt, Char>::value&&
190template <
typename S,
typename... Args,
typename Char =
char_t<S>,
193 detail::counting_buffer<Char> buf;
207 vprint(stdout, fmt, args);
210template <
typename... T>
\rst Parsing context consisting of a format string range being parsed and an argument counter for aut...
Definition: core.h:654
An implementation of std::basic_string_view for pre-C++17.
Definition: core.h:430
\rst A contiguous memory buffer with an optional growing ability.
Definition: core.h:862
FMT_CONSTEXPR20 void push_back(const T &value)
Definition: core.h:931
FMT_CONSTEXPR auto data() noexcept -> T *
Returns a pointer to the buffer data.
Definition: core.h:908
std::integral_constant< bool, B > bool_constant
Definition: core.h:301
typename detail::char_t_impl< S >::type char_t
String's character type.
Definition: core.h:644
#define FMT_MODULE_EXPORT_BEGIN
Definition: core.h:224
constexpr auto make_format_args(Args &&... args) -> format_arg_store< Context, remove_cvref_t< Args >... >
\rst Constructs a ~fmtformat_arg_store object that contains references to arguments and can be implic...
Definition: core.h:1923
type
Definition: core.h:575
#define FMT_BEGIN_NAMESPACE
Definition: core.h:214
#define FMT_ENABLE_IF(...)
Definition: core.h:335
auto get_iterator(Buffer &buf) -> decltype(buf.out())
Definition: core.h:1115
FMT_INLINE auto to_string_view(const Char *s) -> basic_string_view< Char >
Definition: core.h:536
typename type_identity< T >::type type_identity_t
Definition: core.h:309
#define FMT_END_NAMESPACE
Definition: core.h:217
#define FMT_MODULE_EXPORT_END
Definition: core.h:225
static EIGEN_DEPRECATED const end_t end
Definition: IndexedViewHelper.h:181
Definition: format-inl.h:32
decltype(std::end(std::declval< T & >())) sentinel_t
Definition: format.h:476
bool_constant<!std::is_same< T, char >::value > is_exotic_char
Definition: xchar.h:18
char8_type
Definition: format.h:577
std::string to_string(const T &t)
Definition: base.h:93
cubed< length::millimeter > L
Definition: volume.h:49
Specifies if T is a character type.
Definition: core.h:523
Definition: format.h:3937
#define S(label, offset, message)
Definition: Errors.h:119
auto format(wformat_string< T... > fmt, T &&... args) -> std::wstring
Definition: xchar.h:87
auto vformat_to(OutputIt out, const S &format_str, basic_format_args< buffer_context< type_identity_t< Char > > > args) -> OutputIt
Definition: xchar.h:124
auto vformat(basic_string_view< Char > format_str, basic_format_args< buffer_context< type_identity_t< Char > > > args) -> std::basic_string< Char >
Definition: xchar.h:78
auto format_to(OutputIt out, const S &fmt, Args &&... args) -> OutputIt
Definition: xchar.h:136
basic_string_view< wchar_t > wstring_view
Definition: xchar.h:23
constexpr format_arg_store< wformat_context, Args... > make_wformat_args(const Args &... args)
Definition: xchar.h:45
auto vformat_to_n(OutputIt out, size_t n, basic_string_view< Char > format_str, basic_format_args< buffer_context< type_identity_t< Char > > > args) -> format_to_n_result< OutputIt >
Definition: xchar.h:170
auto format_to_n(OutputIt out, size_t n, const S &fmt, const Args &... args) -> format_to_n_result< OutputIt >
Definition: xchar.h:184
auto formatted_size(const S &fmt, Args &&... args) -> size_t
Definition: xchar.h:192
auto to_wstring(const T &value) -> std::wstring
Converts value to std::wstring using the default format for type T.
Definition: xchar.h:222
auto join(It begin, Sentinel end, wstring_view sep) -> join_view< It, Sentinel, wchar_t >
Definition: xchar.h:59
void print(std::FILE *f, wformat_string< T... > fmt, T &&... args)
Definition: xchar.h:211
void vprint(std::FILE *f, wstring_view fmt, wformat_args args)
Definition: xchar.h:199
buffer_context< wchar_t > wformat_context
Definition: xchar.h:25
auto runtime(wstring_view s) -> basic_runtime< wchar_t >
Definition: xchar.h:36