chore(deps): update dependency fmt to v11 #502
Merged
+4
−4
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
10.2.1.bcr.1->11.2.010.2.1->11.2.0Release Notes
fmtlib/fmt (fmt)
v11.2.0Compare Source
Added the
sspecifier forstd::error_code. It allows formatting an errormessage as a string. For example:
prints
(The actual message is platform-specific.)
Fixed formatting of
std::chrono::local_timeandtmhttps://github.com/fmtlib/fmt/issues/381515https://github.com/fmtlib/fmt/issues/43504350).
For example (godbolt):
is now formatted consistenly across platforms.
Added diagnostics for cases when timezone information is not available.
For example:
now gives a compile-time error.
Deprecated
fmt::localtimein favor ofstd::localtime.Fixed compilation with GCC 15 and C++20 modules enabled
https://github.com/fmtlib/fmt/pull/434747). Thanks @tkhyn.
Fixed handling of named arguments in format specs
https://github.com/fmtlib/fmt/issues/436060https://github.com/fmtlib/fmt/pull/43614361). Thanks @dinomight.
Added error reporting for duplicate named arguments
https://github.com/fmtlib/fmt/pull/436767). Thanks @dinomight.
Fixed formatting of
longwithFMT_BUILTIN_TYPES=0https://github.com/fmtlib/fmt/issues/437575https://github.com/fmtlib/fmt/issues/43944394).
Optimized
text_styleusing bit packinghttps://github.com/fmtlib/fmt/pull/436363). Thanks @LocalSpook.
Added support for incomplete types (https://github.com/fmtlib/fmt/issues/3180,
https://github.com/fmtlib/fmt/pull/438383). Thanks @LocalSpook.
Fixed a flush issue in
fmt::printwhen using libstdc++https://github.com/fmtlib/fmt/issues/439898).
Fixed
fmt::printlnusage withFMT_ENFORCE_COMPILE_STRINGand legacycompile-time checkshttps://github.com/fmtlib/fmt/pull/440707).
Thanks @madmaxoft.
Removed legacy header
fmt/core.hfrom docshttps://github.com/fmtlib/fmt/pull/442121https://github.com/fmtlib/fmt/pull/44224422). Thanks @krzysztofkortas.
Worked around limitations of
__builtin_strlenduring constant evaluationhttps://github.com/fmtlib/fmt/issues/442323https://github.com/fmtlib/fmt/pull/44294429). Thanks @BRevzin.
Worked around a bug in MSVC v141 (https://github.com/fmtlib/fmt/issues/4412,
https://github.com/fmtlib/fmt/pull/441313). Thanks @hirohira9119.
Removed the
fmt_detailnamespacehttps://github.com/fmtlib/fmt/issues/432424).
Removed specializations of
std::is_floating_pointin testshttps://github.com/fmtlib/fmt/issues/441717).
Fixed a CMake error when setting
CMAKE_MODULE_PATHin the pedantic modehttps://github.com/fmtlib/fmt/pull/442626). Thanks @rlalik.
Updated the Bazel config (https://github.com/fmtlib/fmt/pull/4400).
Thanks @Vertexwahn.
v11.1.4Compare Source
Fixed ABI compatibility with earlier 11.x versions on Windows
https://github.com/fmtlib/fmt/issues/435959).
Improved the logic of switching between fixed and exponential format for
float(https://github.com/fmtlib/fmt/issues/3649).Moved
is_compiled_stringto the public APIhttps://github.com/fmtlib/fmt/issues/434242). Thanks @SwooshyCueb.
Simplified implementation of
operator""_cfhttps://github.com/fmtlib/fmt/pull/434949). Thanks @LocalSpook.
Fixed
__builtin_strlendetection (https://github.com/fmtlib/fmt/pull/4329).Thanks @LocalSpook.
Fixed handling of BMI paths with the Ninja generator
https://github.com/fmtlib/fmt/pull/434444). Thanks @tkhyn.
Fixed gcc 8.3 compile errors (https://github.com/fmtlib/fmt/issues/4331,
https://github.com/fmtlib/fmt/pull/433636). Thanks @sergiud.
Fixed a bogus MSVC warning (https://github.com/fmtlib/fmt/pull/4356).
Thanks @dinomight.
v11.1.3Compare Source
Fixed compilation on GCC 9.4 (https://github.com/fmtlib/fmt/issues/4313).
Worked around an internal compiler error when using C++20 modules with GCC
14.2 and earlierhttps://github.com/fmtlib/fmt/issues/429595).
Worked around a bug in GCC 6 (https://github.com/fmtlib/fmt/issues/4318).
Fixed an issue caused by instantiating
formatter<const T>https://github.com/fmtlib/fmt/issues/430303https://github.com/fmtlib/fmt/pull/43254325). Thanks @timsong-cpp.
Fixed formatting into
std::ostreambuf_iteratorwhen using format stringcompilationhttps://github.com/fmtlib/fmt/issues/430909https://github.com/fmtlib/fmt/pull/43124312). Thanks @phprus.
Restored a constraint on the map formatter so that it correctly reports as
unformattable when the element ishttps://github.com/fmtlib/fmt/pull/432626).
Thanks @timsong-cpp.
Reduced the size of format specs (https://github.com/fmtlib/fmt/issues/4298).
Readded
args()tofmt::format_contexthttps://github.com/fmtlib/fmt/issues/430707https://github.com/fmtlib/fmt/pull/43104310). Thanks @Erroneous1.
Fixed a bogus MSVC warning (https://github.com/fmtlib/fmt/issues/4314,
https://github.com/fmtlib/fmt/pull/432222). Thanks @ZehMatt.
Fixed a pedantic mode error in the CMake config
https://github.com/fmtlib/fmt/pull/432727). Thanks @rlalik.
v11.1.2Compare Source
Fixed ABI compatibility with earlier 11.x versions
https://github.com/fmtlib/fmt/issues/429292).
Added
wchar_tsupport to thestd::bitsetformatterhttps://github.com/fmtlib/fmt/issues/428585https://github.com/fmtlib/fmt/pull/428642https://github.com/fmtlib/fmt/issues/4289s/https://github.com/fmtlib/fmt/pull/4290ull/4290). Thanks @phprus.
Prefixed CMake components with
fmt-to simplify usage of {fmt} viaadd_subdirectory(https://github.com/fmtlib/fmt/issues/4283).Updated docs for meson (https://github.com/fmtlib/fmt/pull/4291).
Thanks @trim21.
Fixed a compilation error in chrono on nvcc
https://github.com/fmtlib/fmt/issues/429797https://github.com/fmtlib/fmt/pull/43014301). Thanks @breyerml.
Fixed various warnings
https://github.com/fmtlib/fmt/pull/428888https://github.com/fmtlib/fmt/pull/42994299). Thanks @GamesTrap and @edo9300.
v11.1.1Compare Source
Fixed ABI compatibility with earlier 11.x versions
https://github.com/fmtlib/fmt/issues/427878).
Defined CMake components (
coreanddoc) to allow docs to be installedseparatelyhttps://github.com/fmtlib/fmt/pull/427676).
Thanks @carlsmedstad.
v11.1.0Improved C++20 module support
https://github.com/fmtlib/fmt/issues/408181https://github.com/fmtlib/fmt/pull/408340https://github.com/fmtlib/fmt/pull/4084l/https://github.com/fmtlib/fmt/pull/4152ulhttps://github.com/fmtlib/fmt/issues/4153sshttps://github.com/fmtlib/fmt/pull/4169mthttps://github.com/fmtlib/fmt/issues/4190mthttps://github.com/fmtlib/fmt/issues/4234/fhttps://github.com/fmtlib/fmt/pull/4239tlib/fmt/pull/4239).
Thanks @kamrann and @Arghnews.
Reduced debug (unoptimized) binary code size and the number of template
instantiations when passing formatting arguments. For example, unoptimized
binary code size for
fmt::print("{}", 42)was reduced by ~40% on GCC and~60% on clang (x86-64).
GCC:
(godbolt).
(godbolt).
Clang:
(godbolt).
(godbolt).
Added an experimental
fmt::writerAPI that can be used for writing todifferent destinations such as files or stringshttps://github.com/fmtlib/fmt/issues/23542354).
For example (godbolt):
Added width and alignment support to the formatter of
std::error_code.Made
std::expected<void, E>formattablehttps://github.com/fmtlib/fmt/issues/414545https://github.com/fmtlib/fmt/pull/41484148).
For example (godbolt):
prints
Thanks @phprus.
Made
fmt::is_formattable<void>SFINAE-friendlyhttps://github.com/fmtlib/fmt/issues/414747).
Added support for
_BitIntformatting when using clanghttps://github.com/fmtlib/fmt/issues/400707https://github.com/fmtlib/fmt/pull/407240https://github.com/fmtlib/fmt/issues/4140s/https://github.com/fmtlib/fmt/issues/4173uehttps://github.com/fmtlib/fmt/pull/4176/pull/4176).
For example (godbolt):
Thanks @Arghnews.
Added the
nspecifier for tuples and pairshttps://github.com/fmtlib/fmt/pull/410707). Thanks @someonewithpc.
Added support for tuple-like types to
fmt::joinhttps://github.com/fmtlib/fmt/issues/422626https://github.com/fmtlib/fmt/pull/42304230). Thanks @phprus.
Made more types formattable at compile time
https://github.com/fmtlib/fmt/pull/412727). Thanks @AnthonyVH.
Implemented a more efficient compile-time
fmt::formatted_sizehttps://github.com/fmtlib/fmt/issues/410202https://github.com/fmtlib/fmt/pull/41034103). Thanks @phprus.
Fixed compile-time formatting of some string types
https://github.com/fmtlib/fmt/pull/406565). Thanks @torshepherd.
Made compiled version of
fmt::format_towork withstd::back_insert_iterator<std::vector<char>>https://github.com/fmtlib/fmt/issues/420606https://github.com/fmtlib/fmt/pull/42114211). Thanks @phprus.
Added a formatter for
std::reference_wrapperhttps://github.com/fmtlib/fmt/pull/416363https://github.com/fmtlib/fmt/pull/41644164). Thanks @yfeldblum and @phprus.
Added experimental padding support (glibc
strftimeextension) to%m,%jand
%Y(https://github.com/fmtlib/fmt/pull/4161). Thanks @KKhanhH.Made microseconds formatted as
usinstead ofµsif the Unicode support isdisabledhttps://github.com/fmtlib/fmt/issues/408888).
Fixed an unreleased regression in transcoding of surrogate pairs
https://github.com/fmtlib/fmt/issues/409494https://github.com/fmtlib/fmt/pull/40954095). Thanks @phprus.
Made
fmt::appendersatisfystd::output_iteratorconcepthttps://github.com/fmtlib/fmt/issues/409292https://github.com/fmtlib/fmt/pull/40934093). Thanks @phprus.
Made
std::iterator_traits<fmt::appender>standard-conforminghttps://github.com/fmtlib/fmt/pull/418585). Thanks @CaseyCarter.
Made it easier to reuse
fmt::formatter<std::string_view>for types withan implicit conversion to
std::string_viewhttps://github.com/fmtlib/fmt/issues/403636https://github.com/fmtlib/fmt/pull/40554055). Thanks @Arghnews.
Made it possible to disable
<filesystem>use viaFMT_CPP_LIB_FILESYSTEMfor compatibility with some video game console SDKs, e.g. Nintendo Switch SDKhttps://github.com/fmtlib/fmt/issues/425742https://github.com/fmtlib/fmt/pull/4258l/https://github.com/fmtlib/fmt/pull/4259ull/4259). Thanks @W4RH4WK and @phprus.
Fixed compatibility with platforms that use 80-bit
long doublehttps://github.com/fmtlib/fmt/issues/424545https://github.com/fmtlib/fmt/pull/42464246). Thanks @jsirpoma.
Added support for UTF-32 code units greater than
0xFFFFin fillhttps://github.com/fmtlib/fmt/issues/420101).
Fixed handling of legacy encodings on Windows with GCC
https://github.com/fmtlib/fmt/issues/416262).
Made
fmt::to_stringtakefmt::basic_memory_bufferby const referencehttps://github.com/fmtlib/fmt/issues/426161https://github.com/fmtlib/fmt/pull/42624262). Thanks @sascha-devel.
Added
fmt::dynamic_format_arg_store::sizehttps://github.com/fmtlib/fmt/pull/427070). Thanks @hannes-harnisch.
Removed the ability to control locale usage via an undocumented
FMT_STATIC_THOUSANDS_SEPARATORin favor ofFMT_USE_LOCALE.Renamed
FMT_EXCEPTIONStoFMT_USE_EXCEPTIONSfor consistency with othersimilar macros.
Improved include directory ordering to reduce the chance of including
incorrect headers when using multiple versions of {fmt}https://github.com/fmtlib/fmt/pull/41164116). Thanks @cdzhan.
Made it possible to compile a subset of {fmt} without the C++ runtime.
Improved documentation and README
https://github.com/fmtlib/fmt/pull/406666https://github.com/fmtlib/fmt/issues/411741https://github.com/fmtlib/fmt/issues/4203s/https://github.com/fmtlib/fmt/pull/4235ull/4235). Thanks @zyctree and @nikola-sh.
Improved the documentation generator (https://github.com/fmtlib/fmt/pull/4110,
https://github.com/fmtlib/fmt/pull/411515). Thanks @rturrado.
Improved CI (https://github.com/fmtlib/fmt/pull/4155,
https://github.com/fmtlib/fmt/pull/415151). Thanks @phprus.
Fixed various warnings and compilation issues
https://github.com/fmtlib/fmt/issues/270808https://github.com/fmtlib/fmt/issues/409140https://github.com/fmtlib/fmt/issues/4109s/https://github.com/fmtlib/fmt/issues/4113uehttps://github.com/fmtlib/fmt/issues/4125sshttps://github.com/fmtlib/fmt/issues/4129/ihttps://github.com/fmtlib/fmt/pull/4130/fhttps://github.com/fmtlib/fmt/pull/4131ibhttps://github.com/fmtlib/fmt/pull/4132tlhttps://github.com/fmtlib/fmt/issues/4133tlhttps://github.com/fmtlib/fmt/issues/4144fmhttps://github.com/fmtlib/fmt/issues/4150m/https://github.com/fmtlib/fmt/issues/4158cohttps://github.com/fmtlib/fmt/pull/4159huhttps://github.com/fmtlib/fmt/issues/4160huhttps://github.com/fmtlib/fmt/pull/4170/ghttps://github.com/fmtlib/fmt/issues/4177/ghttps://github.com/fmtlib/fmt/pull/4187pshttps://github.com/fmtlib/fmt/pull/4188tthttps://github.com/fmtlib/fmt/pull/4194 hhttps://github.com/fmtlib/fmt/pull/4200
https://github.com/fmtlib/fmt/issues/4205
https://github.com/fmtlib/fmt/issues/42075,https://github.com/fmtlib/fmt/pull/4208/4https://github.com/fmtlib/fmt/pull/4210llhttps://github.com/fmtlib/fmt/issues/4220llhttps://github.com/fmtlib/fmt/issues/4231suhttps://github.com/fmtlib/fmt/issues/4232ishttps://github.com/fmtlib/fmt/pull/4233fmhttps://github.com/fmtlib/fmt/pull/4236lihttps://github.com/fmtlib/fmt/pull/4267mthttps://github.com/fmtlib/fmt/pull/4271/Use the _MSVC_STL_UPDATE macro to detect STL fmtlib/fmt#4267,
Fix compatibility with older versions of VS fmtlib/fmt#4271).
Thanks @torsten48, @Arghnews, @tinfoilboy, @aminya, @Ottani, @zeroomega,
@c4v4, @kongy, @vinayyadav3016, @sergio-nsk, @phprus and @YexuanXiao.
v11.0.2Compare Source
Fixed compatibility with non-POSIX systems
https://github.com/fmtlib/fmt/issues/405454https://github.com/fmtlib/fmt/issues/40604060).
Fixed performance regressions when using
std::back_insert_iteratorwithfmt::format_to(https://github.com/fmtlib/fmt/issues/4070).Fixed handling of
std::generatorand move-only iteratorshttps://github.com/fmtlib/fmt/issues/405353https://github.com/fmtlib/fmt/pull/40574057). Thanks @Arghnews.
Made
formatter<std::string_view>::parsework with types convertible tostd::string_view(https://github.com/fmtlib/fmt/issues/4036,https://github.com/fmtlib/fmt/pull/405555). Thanks @Arghnews.
Made
volatile void*formattablehttps://github.com/fmtlib/fmt/issues/404949https://github.com/fmtlib/fmt/pull/40564056). Thanks @Arghnews.
Made
Glib::ustringnot be confused withstd::stringhttps://github.com/fmtlib/fmt/issues/405252).
Made
fmt::contextiterator compatible with STL algorithms that rely oniterator categoryhttps://github.com/fmtlib/fmt/issues/407979).
v11.0.1Compare Source
Fixed version number in the inline namespace
https://github.com/fmtlib/fmt/issues/404747).
Fixed disabling Unicode support via CMake
https://github.com/fmtlib/fmt/issues/405151).
Fixed deprecated
visit_format_arg(https://github.com/fmtlib/fmt/pull/4043).Thanks @nebkat.
Fixed handling of a sign and improved the
std::complexformaterhttps://github.com/fmtlib/fmt/pull/403434https://github.com/fmtlib/fmt/pull/40504050). Thanks @tesch1 and @phprus.
Fixed ADL issues in
fmt::printfwhen using C++20https://github.com/fmtlib/fmt/pull/404242). Thanks @toge.
Removed a redundant check in the formatter for
std::expectedhttps://github.com/fmtlib/fmt/pull/404040). Thanks @phprus.
v11.0.0Added
fmt/base.hwhich provides a subset of the API with minimal includedependencies and enough functionality to replace all uses of the
printffamily of functions. This brings the compile time of code using {fmt} much
closer to the equivalent
printfcode as shown on the following benchmarkthat compiles 100 source files:
This gives almost 4x improvement in build speed compared to version 10.
Note that the benchmark is purely formatting code and includes. In real
projects the difference from
printfwill be smaller partly because commonstandard headers will be included in almost any translation unit (TU) anyway.
In particular, in every case except
printfabove ~1s is spent in total onincluding
<type_traits>in all TUs.Optimized includes in other headers such as
fmt/format.hwhich is nowroughly equivalent to the old
fmt/core.hin terms of build speed.Migrated the documentation at https://fmt.dev/ from Sphinx to MkDocs.
Improved C++20 module support
https://github.com/fmtlib/fmt/issues/399090https://github.com/fmtlib/fmt/pull/399139https://github.com/fmtlib/fmt/issues/3993s/https://github.com/fmtlib/fmt/pull/3994ulhttps://github.com/fmtlib/fmt/pull/3997/phttps://github.com/fmtlib/fmt/pull/3998mthttps://github.com/fmtlib/fmt/pull/4004/fhttps://github.com/fmtlib/fmt/pull/4005ibhttps://github.com/fmtlib/fmt/pull/4006tlhttps://github.com/fmtlib/fmt/pull/4013fmhttps://github.com/fmtlib/fmt/pull/4027m/https://github.com/fmtlib/fmt/pull/4029com/Module purview can only contain direct preprocessor code fmtlib/fmt#4029). In particular, native CMake support
for modules is now used if available. Thanks @yujincheng08 and @matt77hias.
Added an option to replace standard includes with
import stdenabled viathe
FMT_IMPORT_STDmacro (https://github.com/fmtlib/fmt/issues/3921,https://github.com/fmtlib/fmt/pull/392828). Thanks @matt77hias.
Exported
fmt::range_format,fmt::range_format_kindandfmt::compiled_stringfrom thefmtmodulehttps://github.com/fmtlib/fmt/pull/397070https://github.com/fmtlib/fmt/pull/39993999).
Thanks @matt77hias and @yujincheng08.
Improved integration with stdio in
fmt::print, enabling direct writesinto a C stream buffer in common cases. This may give significant
performance improvements ranging from tens of percent to 2x and eliminates dynamic memory
allocations on the buffer level. It is currently enabled for built-in and
string types with wider availability coming up in future releases.
For example, it gives ~24% improvement on a simple benchmark compiled with Apple clang
version 15.0.0 (clang-1500.1.0.2.5) and run on macOS 14.2.1:
Improved safety of
fmt::format_towhen writing to an arrayhttps://github.com/fmtlib/fmt/pull/380505).
For example (godbolt):
no longer results in a buffer overflow. Instead the output will be truncated
and you can get the end iterator and whether truncation occurred from the
resultobject. Thanks @ThePhD.Enabled Unicode support by default in MSVC, bringing it on par with other
compilers and making it unnecessary for users to enable it explicitly.
Most of {fmt} is encoding-agnostic but this prevents mojibake in places
where encoding matters such as path formatting and terminal output.
You can control the Unicode support via the CMake
FMT_UNICODEoption.Note that some {fmt} packages such as the one in vcpkg have already been
compiled with Unicode enabled.
Added a formatter for
std::expectedhttps://github.com/fmtlib/fmt/pull/383434). Thanks @dominicpoeschko.
Added a formatter for
std::complexhttps://github.com/fmtlib/fmt/issues/146767https://github.com/fmtlib/fmt/issues/388638https://github.com/fmtlib/fmt/pull/3892l/https://github.com/fmtlib/fmt/pull/3900ull/3900). Thanks @phprus.
Added a formatter for
std::type_infohttps://github.com/fmtlib/fmt/pull/397878). Thanks @matt77hias.
Specialized
formatterforstd::basic_stringtypes with custom traitsand allocatorshttps://github.com/fmtlib/fmt/issues/393838https://github.com/fmtlib/fmt/pull/39433943). Thanks @dieram3.
Added formatters for
std::chrono::day,std::chrono::month,std::chrono::yearandstd::chrono::year_month_dayhttps://github.com/fmtlib/fmt/issues/375858https://github.com/fmtlib/fmt/issues/377237https://github.com/fmtlib/fmt/pull/3906l/https://github.com/fmtlib/fmt/pull/3913ull/3913). For example:
prints a green day:
Thanks @zivshek.
Fixed handling of precision in
%S(https://github.com/fmtlib/fmt/issues/3794,https://github.com/fmtlib/fmt/pull/381414). Thanks @js324.
Added support for the
-specifier (glibcstrftimeextension) to day ofthe month (
%d) and week of the year (%W,%U,%V) specifiershttps://github.com/fmtlib/fmt/pull/397676). Thanks @ZaheenJ.
Fixed the scope of the
-extension in chrono formatting so that it doesn'tapply to subsequent specifiershttps://github.com/fmtlib/fmt/issues/381111https://github.com/fmtlib/fmt/pull/38123812). Thanks @phprus.
Improved handling of
time_point::min()https://github.com/fmtlib/fmt/issues/328282).
Added support for character range formatting
https://github.com/fmtlib/fmt/issues/385757https://github.com/fmtlib/fmt/pull/38633863). Thanks @js324.
Added
stringanddebug_stringrange formattershttps://github.com/fmtlib/fmt/pull/397373https://github.com/fmtlib/fmt/pull/40244024). Thanks @matt77hias.
Enabled ADL for
beginandendinfmt::joinhttps://github.com/fmtlib/fmt/issues/381313https://github.com/fmtlib/fmt/pull/38243824). Thanks @bbolli.
Made contiguous iterator optimizations apply to
std::basic_stringiteratorshttps://github.com/fmtlib/fmt/pull/379898). Thanks @phprus.
Added support for ranges with mutable
beginandendhttps://github.com/fmtlib/fmt/issues/375252https://github.com/fmtlib/fmt/pull/380038https://github.com/fmtlib/fmt/pull/3955l/3955). Thanks @tcbrindle and @Arghnews.
Added support for move-only iterators to
fmt::joinhttps://github.com/fmtlib/fmt/issues/380202https://github.com/fmtlib/fmt/pull/39463946). Thanks @Arghnews.
Moved range and iterator overloads of
fmt::jointofmt/ranges.h, nextto other overloads.
Fixed handling of types with
beginreturningvoidsuch as Eigen matriceshttps://github.com/fmtlib/fmt/issues/383939https://github.com/fmtlib/fmt/pull/39643964). Thanks @Arghnews.
Added an
fmt::formattableconcept (https://github.com/fmtlib/fmt/pull/3974).Thanks @matt77hias.
Added support for
__float128(https://github.com/fmtlib/fmt/issues/3494).Fixed rounding issues when formatting
long doublewith fixed precisionhttps://github.com/fmtlib/fmt/issues/353939).
Made
fmt::isnannot trigger floating-point exception for NaN valueshttps://github.com/fmtlib/fmt/issues/394848https://github.com/fmtlib/fmt/pull/39513951). Thanks @alexdewar.
Removed dependency on
<memory>forstd::allocator_traitswhen possiblehttps://github.com/fmtlib/fmt/pull/380404). Thanks @phprus.
Enabled compile-time checks in formatting functions that take text colors and
styles.
Deprecated wide stream overloads of
fmt::printthat take text styles.Made format string compilation work with clang 12 and later despite
only partial non-type template parameter supporthttps://github.com/fmtlib/fmt/issues/400040https://github.com/fmtlib/fmt/pull/4001l/4001). Thanks @yujincheng08.
Made
fmt::iterator_buffer's move constructornoexcepthttps://github.com/fmtlib/fmt/pull/380808). Thanks @waywardmonkeys.
Started enforcing that
formatter::formatis const for compatibilitywith
std::format(https://github.com/fmtlib/fmt/issues/3447).Added
fmt::basic_format_arg::visitand deprecatedfmt::visit_format_arg.Made
fmt::basic_string_viewnot constructible fromnullptrforconsistency with
std::string_viewin C++23https://github.com/fmtlib/fmt/pull/384646). Thanks @dalle.
Fixed
fmt::group_digitsfor negative integershttps://github.com/fmtlib/fmt/issues/389191https://github.com/fmtlib/fmt/pull/39013901). Thanks @phprus.
Fixed handling of negative ids in
fmt::basic_format_args::gethttps://github.com/fmtlib/fmt/pull/394545). Thanks @marlenecota.
Fixed handling of a buffer boundary on flush
https://github.com/fmtlib/fmt/issues/422929).
Improved named argument validation
https://github.com/fmtlib/fmt/issues/381717).
Disabled copy construction/assignment for
fmt::format_arg_storeandfixed moved constructionhttps://github.com/fmtlib/fmt/pull/383333).
Thanks @ivafanas.
Worked around a locale issue in RHEL/devtoolset
https://github.com/fmtlib/fmt/issues/385858https://github.com/fmtlib/fmt/pull/38593859). Thanks @g199209.
Added RTTI detection for MSVC (https://github.com/fmtlib/fmt/pull/3821,
https://github.com/fmtlib/fmt/pull/396363). Thanks @edo9300.
Migrated the documentation from Sphinx to MkDocs.
Improved documentation and README
https://github.com/fmtlib/fmt/issues/377575https://github.com/fmtlib/fmt/pull/378437https://github.com/fmtlib/fmt/issues/3788s/https://github.com/fmtlib/fmt/pull/3789ulhttps://github.com/fmtlib/fmt/pull/3793/phttps://github.com/fmtlib/fmt/issues/3818/ihttps://github.com/fmtlib/fmt/pull/3820/fhttps://github.com/fmtlib/fmt/pull/3822ibhttps://github.com/fmtlib/fmt/pull/3843tlhttps://github.com/fmtlib/fmt/pull/3890fmhttps://github.com/fmtlib/fmt/issues/3894fmhttps://github.com/fmtlib/fmt/pull/3895cohttps://github.com/fmtlib/fmt/pull/3905b.https://github.com/fmtlib/fmt/issues/3942b.https://github.com/fmtlib/fmt/pull/4008ithub.com/README.md: update to remove "not yet release" remarks on clang-tidy fmtlib/fmt#4008).
Thanks @zencatalyst, WolleTD, @tupaschoal, @Dobiasd, @frank-weinberg, @bbolli,
@phprus, @waywardmonkeys, @js324 and @tchaikov.
Improved CI and tests
https://github.com/fmtlib/fmt/issues/387878https://github.com/fmtlib/fmt/pull/388338https://github.com/fmtlib/fmt/issues/3897s/https://github.com/fmtlib/fmt/pull/3979ulhttps://github.com/fmtlib/fmt/pull/3980/phttps://github.com/fmtlib/fmt/pull/3988mthttps://github.com/fmtlib/fmt/pull/4010/fhttps://github.com/fmtlib/fmt/pull/4012ibhttps://github.com/fmtlib/fmt/pull/4038tlib/fmt/pull/4038).
Thanks @vgorrX, @waywardmonkeys, @tchaikov and @phprus.
Fixed buffer overflow when using format string compilation with debug format
and
std::back_insert_iterator(https://github.com/fmtlib/fmt/issues/3795,https://github.com/fmtlib/fmt/pull/379797). Thanks @phprus.
Improved Bazel support
https://github.com/fmtlib/fmt/pull/379292https://github.com/fmtlib/fmt/pull/380138https://github.com/fmtlib/fmt/pull/3962l/https://github.com/fmtlib/fmt/pull/3965ull/3965). Thanks @Vertexwahn.
Improved/fixed the CMake config
https://github.com/fmtlib/fmt/issues/377777https://github.com/fmtlib/fmt/pull/378337https://github.com/fmtlib/fmt/issues/3847s/https://github.com/fmtlib/fmt/pull/3907ull/3907). Thanks @phprus and @xTachyon.
Fixed various warnings and compilation issues
https://github.com/fmtlib/fmt/issues/368585https://github.com/fmtlib/fmt/issues/376937https://github.com/fmtlib/fmt/issues/3796s/https://github.com/fmtlib/fmt/issues/3803uehttps://github.com/fmtlib/fmt/pull/3806/phttps://github.com/fmtlib/fmt/pull/3807mthttps://github.com/fmtlib/fmt/issues/3809mthttps://github.com/fmtlib/fmt/pull/3810ibhttps://github.com/fmtlib/fmt/issues/3830ibhttps://github.com/fmtlib/fmt/pull/3832fmhttps://github.com/fmtlib/fmt/issues/3835fmhttps://github.com/fmtlib/fmt/pull/3844cohttps://github.com/fmtlib/fmt/issues/3854cohttps://github.com/fmtlib/fmt/pull/3856huhttps://github.com/fmtlib/fmt/pull/3865ithttps://github.com/fmtlib/fmt/pull/3866/ghttps://github.com/fmtlib/fmt/pull/3880:/https://github.com/fmtlib/fmt/issues/3881:/https://github.com/fmtlib/fmt/issues/3884pshttps://github.com/fmtlib/fmt/issues/3898tthttps://github.com/fmtlib/fmt/pull/3899
https://github.com/fmtlib/fmt/pull/39099,https://github.com/fmtlib/fmt/pull/391790https://github.com/fmtlib/fmt/pull/3923/3https://github.com/fmtlib/fmt/pull/3924llhttps://github.com/fmtlib/fmt/issues/3925llhttps://github.com/fmtlib/fmt/pull/3930ishttps://github.com/fmtlib/fmt/pull/3931fmhttps://github.com/fmtlib/fmt/pull/3933b/https://github.com/fmtlib/fmt/issues/3935b/https://github.com/fmtlib/fmt/pull/3937lihttps://github.com/fmtlib/fmt/pull/3967/fhttps://github.com/fmtlib/fmt/pull/3968omhttps://github.com/fmtlib/fmt/pull/3972.chttps://github.com/fmtlib/fmt/pull/3983ubhttps://github.com/fmtlib/fmt/issues/3992ubhttps://github.com/fmtlib/fmt/pull/3995thhttps://github.com/fmtlib/fmt/pull/4009//https://github.com/fmtlib/fmt/pull/4023s://github.com/Add FMT_FORCE_FALLBACK_FILE to force the use of fallback_file fmtlib/fmt#4009,
Suppress a bogus warning in MSVC fmtlib/fmt#4023).
Thanks @hmbj, @phprus, @res2k, @Baardi, @matt77hias, @waywardmonkeys, @hmbj,
@yakra, @prlw1, @Arghnews, @mtillmann0, @ShifftC, @eepp, @jimmy-park and
@ChristianGebhardt.
Configuration
📅 Schedule: Branch creation - "every 1 months on the first day of the month" (UTC), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about these updates again.
This PR was generated by Mend Renovate. View the repository job log.