Victor Zverovich
616a493786
Revert Char* formatter removal
2023-05-17 06:11:11 -07:00
Victor Zverovich
aeedac5884
Remove unneeded specialization
2023-05-13 07:46:47 -07:00
Vladislav Shchapov
eaa6307691
Make hex float test more stable ( #3434 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-05-13 06:34:33 -07:00
Victor Zverovich
ea49c91cd1
Cleanup argument construction
2023-05-11 18:43:39 -07:00
June Liu
33f7150778
Fix error C2668 on msvc ( #3378 )
2023-04-11 06:27:28 -07:00
Victor Zverovich
fce74caa15
Disable problematic implicit conversions
2023-04-09 09:08:46 -07:00
Victor Zverovich
02bf4d1c1c
Disable to_string_view ADL
2023-04-09 08:49:05 -07:00
Vladislav Shchapov
97aedeab48
Workaround a double-double hexfloat format ( #3366 )
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2023-04-01 07:19:23 -07:00
Victor Zverovich
41cfc739fe
Generalize format_as
2023-03-26 07:37:51 -07:00
Victor Zverovich
6549ffde8e
Improve format_as safety
2023-03-19 12:09:54 -07:00
Victor Zverovich
98699719f8
Make # handling consistent with std::format
2023-02-26 10:15:16 -08:00
Shawn Zhong
87c066a35b
Implement println
( #3267 )
2023-01-24 12:30:00 -08:00
Victor Zverovich
09ed1ddb9c
Cleanup tests
2023-01-02 09:58:12 -08:00
Victor Zverovich
a05ba44df8
Simplify format string parsing
2022-12-30 11:23:42 -08:00
Victor Zverovich
ffb9b1d13c
Improve handling of signed types
2022-12-30 10:31:39 -08:00
Victor Zverovich
32190859ec
Fix handling of char
2022-12-30 09:11:42 -08:00
Victor Zverovich
dfb857ebef
Refactor format spec parsing
2022-12-25 07:25:32 -08:00
Victor Zverovich
407e7b7b6d
basic_format_specs -> format_specs
2022-12-24 14:34:50 -08:00
Victor Zverovich
934c8e5f76
Refactor precision parsing
2022-12-24 13:29:23 -08:00
Victor Zverovich
9660e5b956
Remove redundant tests
2022-12-24 07:28:13 -08:00
Shawn Zhong
a585571e90
Ignore 0 character with align
2022-12-23 19:36:05 -08:00
Victor Zverovich
1dadeb8a33
Refactor width parsing
2022-12-23 18:29:59 -08:00
Vladislav Shchapov
e004f1d699
Fix for issue #3241
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-12-23 12:26:20 -08:00
Victor Zverovich
bde1a6070d
Simplify fill and alignment parsing
2022-12-23 10:52:56 -08:00
Victor Zverovich
b90895412f
Fix formatting of named arguments with locale
2022-12-15 09:59:40 -08:00
Victor Zverovich
3999fd193a
Workaround an ADL issue
2022-12-11 09:32:17 -08:00
Radek Brich
62ceb181b1
fix #3105 - Compile-time error when mixing named argument with automatic indexing
2022-12-04 08:13:26 -08:00
Vladislav Shchapov
31364732dc
Replace snprintf-based hex float formatter with internal implementation
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-11-24 07:15:46 -08:00
Hans-Martin B. Jensen
7df30f91ae
Format unique_ptr with custom deleter ( #3177 )
...
* Format unique_ptr with custom deleter
Added deleter type to fmt::ptr unique_ptr overload. Deleter type is
part of the unique_ptr type.
* Review: apply clang-format
Co-authored-by: Hans-Martin B. Jensen <haje@eposaudio.com>
2022-11-13 21:54:32 -08:00
Victor Zverovich
0b5cb18b71
Use buffering in to_string to avoid bloat
2022-09-21 17:11:43 -07:00
Victor Zverovich
94ceb38a09
Improve locale API
2022-09-11 09:33:31 -07:00
Victor Zverovich
ecffca6726
Don't parse '}' as fill
2022-09-07 17:33:31 -07:00
gerboengels
3176e0fad7
Add locale overload for formatted_size ( #3084 ) ( #3087 )
...
Co-authored-by: Gerbo Engels <gerbo.engels@ortec-finance.com>
2022-09-07 14:15:12 -07:00
Victor Zverovich
d59b89e9cd
More locale
2022-09-04 11:23:45 -07:00
Victor Zverovich
58a5563a9f
Implement grouping
2022-09-04 09:01:26 -07:00
Victor Zverovich
1b94271ff6
Add support for UTF-8 digit separators
2022-09-03 11:01:05 -07:00
Victor Zverovich
91ecb38a34
Localize negative integers
2022-09-03 07:01:11 -07:00
Victor Zverovich
fec5515c55
num_format_facet -> format_facet
2022-09-02 18:55:08 -07:00
Victor Zverovich
f187274d36
Add loc_value
2022-09-02 13:45:23 -07:00
Vladislav Shchapov
a07411c2b9
Disable compile-time checks for dynamic width/precision test for LCC and compiler without std::is_constant_evaluated()
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-08-29 13:33:48 -07:00
Victor Zverovich
7fb8d33f9d
Fix compile-time width/precision type check
2022-08-09 16:10:02 -07:00
Victor Zverovich
48e0a59222
Implement compile-time checks for dynamic width/precision type
2022-07-22 17:00:40 -07:00
Victor Zverovich
05be7a0764
Use FMT_USE_FLOAT128 instead of __SIZEOF_FLOAT128__
2022-07-10 08:54:34 -07:00
Victor Zverovich
2a1b3ac629
Fix large shift in uint128_fallback
2022-07-10 08:27:21 -07:00
Vladislav Shchapov
115e00e0b9
Replace __cplusplus with FMT_CPLUSPLUS.
...
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
2022-07-04 07:18:21 -07:00
Victor Zverovich
0c06c81da8
Deprecated implicit conversion of enums to ints for consistency with scoped enums
2022-07-03 09:02:22 -07:00
David Chisnall
2471875867
Make the tests pass on a CHERI system.
2022-06-10 07:02:03 -07:00
Victor Zverovich
9d60395953
Fix compilation on ppc64
2022-05-31 13:53:15 -07:00
Victor Zverovich
e927149f8e
Cleanup macros
2022-05-29 17:23:02 -07:00
Victor Zverovich
1761e2666a
Remove FMT_CONSTEXPR_DECL
2022-05-29 16:42:58 -07:00
Victor Zverovich
c83a5d42bb
FMT_MSC_VER -> FMT_MSC_VERSION
2022-05-29 15:39:08 -07:00
Victor Zverovich
7e63b600b6
Make to_string work with __float128
2022-05-29 12:23:57 -07:00
Victor Zverovich
ce246aaf74
Remove deprecated APIs
2022-05-22 07:10:09 -07:00
Victor Zverovich
ae963e444f
Implement constexpr isfinite to avoid producing NaN
2022-05-11 08:43:22 -07:00
Victor Zverovich
358f5a7e50
Make precision computation consistent with width
2022-05-11 06:34:51 -07:00
Vladislav Shchapov
ffb5e6a732
Suppress a -Wliteral-range warning on Apple M1 ( #2861 )
2022-04-19 11:10:18 -07:00
Victor Zverovich
5d804ee7fe
Fix handling of subnormals in exotic FP
2022-04-17 08:56:35 -07:00
Victor Zverovich
f607e3e970
Add __float128 support
2022-04-03 12:58:06 -07:00
Victor Zverovich
96930161f9
Implement 128-bit operator+= for uint128_fallback
2022-03-27 08:07:54 -07:00
Victor Zverovich
db5b8993ac
Fix formatting of std::byte via format_as
2022-03-26 09:01:30 -07:00
timsong-cpp
3d19be282a
Fix #2816 : strip named argument wrappers for compile-time checking
2022-03-18 10:11:14 -07:00
Victor Zverovich
ed18ca3eae
Implement isnan
2022-03-14 20:37:46 -07:00
Victor Zverovich
a204b8dde7
Add initial __float128 support
2022-03-14 19:34:41 -07:00
Victor Zverovich
b6b003b073
Cleanup test
2022-03-14 15:48:38 -07:00
Victor Zverovich
cbc59ca893
Clear moved from memory buffer
2022-02-20 08:12:59 -08:00
Vladislav Shchapov
ea3d326c63
Fix clang -Wliteral-range warning ( #2779 )
2022-02-19 10:52:33 -08:00
Victor Zverovich
aad44f2839
Add fmt::enums::format_as
2022-02-19 08:03:42 -08:00
Victor Zverovich
a0b43bfae2
Add support for 96-bit long double
2022-02-18 18:01:49 -08:00
Victor Zverovich
2c8cd2db34
Fix handling of zero precision
2022-02-18 12:38:30 -08:00
Victor Zverovich
d38f72aff2
Refactor fallback ints
2022-02-17 20:24:42 -08:00
Victor Zverovich
15c2a3bacc
int128_t -> int128_opt
2022-02-17 20:03:25 -08:00
Victor Zverovich
6a13464059
Include 128-bit with other signed integers in specifier check
2022-02-16 16:57:06 -08:00
Barry Revzin
a34a97cc1d
Supporting ? as a string presentation type ( #2674 )
...
* Supporting ? as a string presentation type.
* Supporting ? as a char presentation type.
* Adding iterator_category to counting_iterator.
2022-01-30 08:55:28 -08:00
Victor Zverovich
09fde7f4b8
Add fmt::underlying for enum classes
2022-01-22 08:06:22 -08:00
Victor Zverovich
c28500556a
FMT_NOEXCEPT -> noexcept
2022-01-20 16:55:47 -08:00
Victor Zverovich
1b193e7b37
Deprecate more
2022-01-03 11:13:09 -08:00
Alexey Ochapov
e46392ea2c
deprecate _format UDL in code using FMT_DEPRECATED
2021-12-18 08:33:20 -08:00
Victor Zverovich
215f21a038
Detect overflow on large precision
2021-12-05 07:26:58 -08:00
Victor Zverovich
c472a27818
Fix handling of very large precision in fixed format
2021-11-27 08:23:05 -08:00
Florin Iucha
acad8cfab1
Reformat all source code; no functional changes
...
Before adding the format checker, the mainline should be clean, to
avoid false failures.
2021-11-25 09:15:25 -08:00
Florin Iucha
491ba2dda5
Annotate fmt::format and fmt::formatted_size as [[nodiscard]]
...
This prevents accidentally writing fmt::format when fmt::print was
intended. Other than running tests, there's not a good use case for
discarding the formatted output.
2021-11-25 07:30:30 -08:00
Victor Zverovich
028f227752
Handle implicit conversions in write
2021-10-31 08:58:54 -07:00
Victor Zverovich
894faf3fed
Refactor presentation types
2021-09-06 13:32:33 -07:00
Victor Zverovich
3940de5952
thousands -> group_digits
2021-09-05 06:47:18 -07:00
Victor Zverovich
c4d0f96a6d
Implement format specs in fmt::thousands
2021-09-04 06:56:51 -07:00
Victor Zverovich
3b9c442689
Implement thousands separators without locales
2021-09-04 06:32:46 -07:00
Victor Zverovich
1d7384530e
Add missing presentation type checks for std::string ( #2402 )
2021-07-02 07:51:04 -07:00
Victor Zverovich
e421d52713
Simplify error handling in parse_nonnegative_int
2021-06-14 16:05:37 -07:00
Victor Zverovich
2039dce75f
Detect consteval
2021-06-07 06:57:43 -07:00
Victor Zverovich
206000a017
Workaround pathological conversion ( #2343 )
2021-06-06 07:18:44 -07:00
Victor Zverovich
76ee490468
Move wchar/custom char overloads to xchar.h
2021-06-05 22:57:45 -07:00
Victor Zverovich
e77b22d6da
Deprecate memory buffer overload of format_to
2021-06-05 14:58:36 -07:00
Victor Zverovich
11a14db286
Update format_to taking a buffer and remove undocumented vformat_to overload
2021-05-30 07:57:51 -07:00
Victor Zverovich
486a80e8ef
Move wchar_t overloads to xchar.h
2021-05-30 06:41:39 -07:00
Victor Zverovich
a9a9018191
Move wmemory_buffer to wchar.h
2021-05-29 08:26:04 -07:00
Matthias Liedtke
98b9ff47a1
Align hex floats right as default ( #2317 )
2021-05-28 09:21:01 -07:00
Liedtke
a70a4ae053
Ignore zero-padding for non-finite floating points ( #2310 )
...
* Ignore zero-padding for non-finite floating points
* keep width for non-finite formatting with 0-padding
* clang-format
* preserve alignment
* align code-style
2021-05-27 14:13:05 -07:00
Victor Zverovich
34b8acaef7
More wchar_t-specific API to wchar.h
2021-05-21 18:24:39 -07:00
Victor Zverovich
61b4c923d7
Reduce code bloat
2021-05-20 05:51:45 -07:00
Victor Zverovich
95c358f721
Improve separation between code unit types
2021-05-19 09:06:57 -07:00