MyGit

10.1.0

fmtlib/fmt

版本发布时间: 2023-08-12 23:00:46

fmtlib/fmt最新发布版本:11.0.2(2024-07-20 22:32:04)

Optimized format string compilation resulting in up to 40% speed up in compiled format_to and ~4x speed up in compiled format_to_n on a concatenation benchmark (#3133, #3484).

{fmt} 10.0:

---------------------------------------------------------
Benchmark               Time             CPU   Iterations
---------------------------------------------------------
BM_format_to         78.9 ns         78.9 ns      8881746
BM_format_to_n        568 ns          568 ns      1232089

{fmt} 10.1:

---------------------------------------------------------
Benchmark               Time             CPU   Iterations
---------------------------------------------------------
BM_format_to         54.9 ns         54.9 ns     12727944
BM_format_to_n        133 ns          133 ns      5257795

Optimized storage of an empty allocator in basic_memory_buffer (#3485). Thanks @Minty-Meeo.

Added formatters for proxy references to elements of std::vector<bool> and std::bitset<N> (#3567, #3570). For example (godbolt):

#include <vector>
#include <fmt/std.h>

int main() {
  auto v = std::vector<bool>{true};
  fmt::print("{}", v[0]);
}

Thanks @phprus (Vladislav Shchapov) and @felix642 (Félix-Antoine Constantin).

Fixed an ambiguous formatter specialization for containers that look like container adaptors such as boost::flat_set (#3556, #3561). Thanks @5chmidti.

Fixed compilation when formatting durations not convertible from std::chrono::seconds (#3430). Thanks @patlkli (Patrick Geltinger).

Made the formatter specialization for char* const-correct (#3432). Thanks @timsong-cpp.

Made {} and {:} handled consistently during compile-time checks (#3526).

Disallowed passing temporaries to make_format_args to improve API safety by preventing dangling references.

Improved the compile-time error for unformattable types (#3478). Thanks @BRevzin (Barry Revzin).

Improved the floating-point formatter (#3448, #3450). Thanks @florimond-collette (Florimond Collette).

Fixed handling of precision for long double larger than 64 bits. (#3539, #3564).

Made floating-point and chrono tests less platform-dependent (#3337, #3433, #3434). Thanks @phprus (Vladislav Shchapov).

Removed the remnants of the Grisu floating-point formatter that has been replaced by Dragonbox in earlier versions.

Added throw_format_error to the public API (#3551). Thanks @mjerabek (Martin Jeřábek).

Made FMT_THROW assert even if assertions are disabled when compiling with exceptions disabled (#3418, #3439). Thanks @BRevzin (Barry Revzin).

Made format_as and std::filesystem::path formatter work with exotic code unit types. (#3457, #3476). Thanks @gix (Nico Rieck), @hmbj (Hans-Martin B. Jensen).

Deprecated the wide stream overload of printf.

Removed unused basic_printf_parse_context.

Improved RTTI detection used when formatting exceptions (#3468). Thanks @danakj (Dana Jansens).

Improved compatibility with VxWorks7 (#3467). Thanks @wenshan1 (Bin Lan).

Improved documentation (#3174, #3423, #3454, #3458, #3461, #3487, #3515). Thanks @zencatalyst (Kasra Hashemi), @rlalik, @mikecrowe (Mike Crowe).

Improved build and CI configurations (#3449, #3451, #3452, #3453, #3459, #3481, #3486, #3489, #3496, #3517, #3523, #3563). Thanks @joycebrum (Joyce), @glebm (Gleb Mazovetskiy), @phprus (Vladislav Shchapov), @petrmanek (Petr Mánek), @setoye (Alta), @abouvier (Alexandre Bouvier).

Fixed various warnings and compilation issues (#3408, #3424, #3444, #3446, #3475, #3482, #3492, #3493, #3508, #3509, #3533, #3542, #3543, #3540, #3544, #3548, #3549, #3550, #3552). Thanks @adesitter (Arnaud Desitter), @hmbj (Hans-Martin B. Jensen), @Minty-Meeo, @phprus (Vladislav Shchapov), @TobiSchluter (Tobias Schlüter), @kieranclancy (Kieran Clancy), @alexeedm (Dmitry Alexeev), @jurihock (Jürgen Hock), @Ozomahtli, @razaqq.

Pull Requests

New Contributors

相关地址:原始地址 下载(tar) 下载(zip)

1、 fmt-10.1.0.zip 1.22MB

查看:2023-08-12发行的版本