/srv/osrm/osrm-backend/third_party/fmt-9.1.0
Edit: /srv/osrm/osrm-backend/third_party/fmt-9.1.0/ChangeLog.rst (211603B)
9.1.0 - 2022-08-27
------------------
* ``fmt::formatted_size`` now works at compile time
(`#3026
`_). For example
(`godbolt `__):
.. code:: c++
#include
int main() {
using namespace fmt::literals;
constexpr size_t n = fmt::formatted_size("{}"_cf, 42);
fmt::print("{}\n", n); // prints 2
}
Thanks `@marksantaniello (Mark Santaniello)
`_.
* Fixed handling of invalid UTF-8
(`#3038 `_,
`#3044 `_,
`#3056 `_).
Thanks `@phprus (Vladislav Shchapov) `_ and
`@skeeto (Christopher Wellons) `_.
* Improved Unicode support in ``ostream`` overloads of ``print``
(`#2994 `_,
`#3001 `_,
`#3025 `_).
Thanks `@dimztimz (Dimitrij Mijoski) `_.
* Fixed handling of the sign specifier in localized formatting on systems with
32-bit ``wchar_t`` (`#3041 `_).
* Added support for wide streams to ``fmt::streamed``
(`#2994 `_).
Thanks `@phprus (Vladislav Shchapov) `_.
* Added the ``n`` specifier that disables the output of delimiters when
formatting ranges (`#2981 `_,
`#2983 `_).
For example (`godbolt `__):
.. code:: c++
#include
#include
int main() {
auto v = std::vector{1, 2, 3};
fmt::print("{:n}\n", v); // prints 1, 2, 3
}
Thanks `@BRevzin (Barry Revzin) `_.
* Worked around problematic ``std::string_view`` constructors introduced in
C++23 (`#3030 `_,
`#3050 `_).
Thanks `@strega-nil-ms (nicole mazzuca) `_.
* Improve handling (exclusion) of recursive ranges
(`#2968 `_,
`#2974 `_).
Thanks `@Dani-Hub (Daniel Krügler) `_.
* Improved error reporting in format string compilation
(`#3055 `_).
* Improved the implementation of
`Dragonbox `_, the algorithm used for
the default floating-point formatting
(`#2984 `_).
Thanks `@jk-jeon (Junekey Jeon) `_.
* Fixed issues with floating-point formatting on exotic platforms.
* Improved the implementation of chrono formatting
(`#3010 `_).
Thanks `@phprus (Vladislav Shchapov) `_.
* Improved documentation
(`#2966 `_,
`#3009 `_,
`#3020 `_,
`#3037 `_).
Thanks `@mwinterb `_,
`@jcelerier (Jean-Michaël Celerier) `_
and `@remiburtin (Rémi Burtin) `_.
* Improved build configuration
(`#2991 `_,
`#2995 `_,
`#3004 `_,
`#3007 `_,
`#3040 `_).
Thanks `@dimztimz (Dimitrij Mijoski) `_ and
`@hwhsu1231 (Haowei Hsu) `_.
* Fixed various warnings and compilation issues
(`#2969 `_,
`#2971 `_,
`#2975 `_,
`#2982 `_,
`#2985 `_,
`#2988 `_,
`#3000 `_,
`#3006 `_,
`#3014 `_,
`#3015 `_,
`#3021 `_,
`#3023 `_,
`#3024 `_,
`#3029 `_,
`#3043 `_,
`#3052 `_,
`#3053 `_,
`#3054 `_).
Thanks `@h-friederich (Hannes Friederich) `_,
`@dimztimz (Dimitrij Mijoski) `_,
`@olupton (Olli Lupton) `_,
`@bernhardmgruber (Bernhard Manfred Gruber)
`_,
`@phprus (Vladislav Shchapov) `_.
9.0.0 - 2022-07-04
------------------
* Switched to the internal floating point formatter for all decimal presentation
formats. In particular this results in consistent rounding on all platforms
and removing the ``s[n]printf`` fallback for decimal FP formatting.
* Compile-time floating point formatting no longer requires the header-only
mode. For example (`godbolt `__):
.. code:: c++
#include
#include
consteval auto compile_time_dtoa(double value) -> std::array {
auto result = std::array();
fmt::format_to(result.data(), FMT_COMPILE("{}"), value);
return result;
}
constexpr auto answer = compile_time_dtoa(0.42);
works with the default settings.
* Improved the implementation of
`Dragonbox `_, the algorithm used for
the default floating-point formatting
(`#2713 `_,
`#2750 `_).
Thanks `@jk-jeon (Junekey Jeon) `_.
* Made ``fmt::to_string`` work with ``__float128``. This uses the internal
FP formatter and works even on system without ``__float128`` support in
``[s]printf``.
* Disabled automatic ``std::ostream`` insertion operator (``operator<<``)
discovery when ``fmt/ostream.h`` is included to prevent ODR violations.
You can get the old behavior by defining ``FMT_DEPRECATED_OSTREAM`` but this
will be removed in the next major release. Use ``fmt::streamed`` or
``fmt::ostream_formatter`` to enable formatting via ``std::ostream`` instead.
* Added ``fmt::ostream_formatter`` that can be used to write ``formatter``
specializations that perform formatting via ``std::ostream``.
For example (`godbolt `__):
.. code:: c++
#include
struct date {
int year, month, day;
friend std::ostream& operator<<(std::ostream& os, const date& d) {
return os << d.year << '-' << d.month << '-' << d.day;
}
};
template <> struct fmt::formatter : ostream_formatter {};
std::string s = fmt::format("The date is {}", date{2012, 12, 9});
// s == "The date is 2012-12-9"
* Added the ``fmt::streamed`` function that takes an object and formats it
via ``std::ostream``.
For example (`godbolt `__):
.. code:: c++
#include
#include
int main() {
fmt::print("Current thread id: {}\n",
fmt::streamed(std::this_thread::get_id()));
}
Note that ``fmt/std.h`` provides a ``formatter`` specialization for
``std::thread::id`` so you don't need to format it via ``std::ostream``.
* Deprecated implicit conversions of unscoped enums to integers for consistency
with scoped enums.
* Added an argument-dependent lookup based ``format_as`` extension API to
simplify formatting of enums.
* Added experimental ``std::variant`` formatting support
(`#2941 `_).
For example (`godbolt `__):
.. code:: c++
#include
#include
int main() {
auto v = std::variant(42);
fmt::print("{}\n", v);
}
prints::
variant(42)
Thanks `@jehelset `_.
* Added experimental ``std::filesystem::path`` formatting support
(`#2865 `_,
`#2902 `_,
`#2917 `_,
`#2918 `_).
For example (`godbolt `__):
.. code:: c++
#include
#include
int main() {
fmt::print("There is no place like {}.", std::filesystem::path("/home"));
}
prints::
There is no place like "/home".
Thanks `@phprus (Vladislav Shchapov) `_.
* Added a ``std::thread::id`` formatter to ``fmt/std.h``.
For example (`godbolt `__):
.. code:: c++
#include
#include
int main() {
fmt::print("Current thread id: {}\n", std::this_thread::get_id());
}
* Added ``fmt::styled`` that applies a text style to an individual argument
(`#2793 `_).
For example (`godbolt `__):
.. code:: c++
#include
#include
int main() {
auto now = std::chrono::system_clock::now();
fmt::print(
"[{}] {}: {}\n",
fmt::styled(now, fmt::emphasis::bold),
fmt::styled("error", fg(fmt::color::red)),
"something went wrong");
}
prints
.. image:: https://user-images.githubusercontent.com/576385/
175071215-12809244-dab0-4005-96d8-7cd911c964d5.png
Thanks `@rbrugo (Riccardo Brugo) `_.
* Made ``fmt::print`` overload for text styles correctly handle UTF-8
(`#2681 `_,
`#2701 `_).
Thanks `@AlexGuteniev (Alex Guteniev) `_.
* Fixed Unicode handling when writing to an ostream.
* Added support for nested specifiers to range formatting
(`#2673 `_).
For example (`godbolt `__):
.. code:: c++
#include
#include
int main() {
fmt::print("{::#x}\n", std::vector{10, 20, 30});
}
prints ``[0xa, 0x14, 0x1e]``.
Thanks `@BRevzin (Barry Revzin) `_.
* Implemented escaping of wide strings in ranges
(`#2904 `_).
Thanks `@phprus (Vladislav Shchapov) `_.
* Added support for ranges with ``begin`` / ``end`` found via the
argument-dependent lookup
(`#2807 `_).
Thanks `@rbrugo (Riccardo Brugo) `_.
* Fixed formatting of certain kinds of ranges of ranges
(`#2787 `_).
Thanks `@BRevzin (Barry Revzin) `_.
* Fixed handling of maps with element types other than ``std::pair``
(`#2944 `_).
Thanks `@BrukerJWD (Jonathan W) `_.
* Made tuple formatter enabled only if elements are formattable
(`#2939 `_,
`#2940 `_).
Thanks `@jehelset `_.
* Made ``fmt::join`` compatible with format string compilation
(`#2719 `_,
`#2720 `_).
Thanks `@phprus (Vladislav Shchapov) `_.
* Made compile-time checks work with named arguments of custom types and
``std::ostream`` ``print`` overloads
(`#2816 `_,
`#2817 `_,
`#2819 `_).
Thanks `@timsong-cpp `_.
* Removed ``make_args_checked`` because it is no longer needed for compile-time
checks (`#2760 `_).
Thanks `@phprus (Vladislav Shchapov) `_.
* Removed the following deprecated APIs: ``_format``, ``arg_join``,
the ``format_to`` overload that takes a memory buffer,
``[v]fprintf`` that takes an ``ostream``.
* Removed the deprecated implicit conversion of ``[const] signed char*`` and
``[const] unsigned char*`` to C strings.
* Removed the deprecated ``fmt/locale.h``.
* Replaced the deprecated ``fileno()`` with ``descriptor()`` in
``buffered_file``.
* Moved ``to_string_view`` to the ``detail`` namespace since it's an
implementation detail.
* Made access mode of a created file consistent with ``fopen`` by setting
``S_IWGRP`` and ``S_IWOTH``
(`#2733 `_).
Thanks `@arogge (Andreas Rogge) `_.
* Removed a redundant buffer resize when formatting to ``std::ostream``
(`#2842 `_,
`#2843 `_).
Thanks `@jcelerier (Jean-Michaël Celerier) `_.
* Made precision computation for strings consistent with width
(`#2888 `_).
* Fixed handling of locale separators in floating point formatting
(`#2830 `_).
* Made sign specifiers work with ``__int128_t``
(`#2773 `_).
* Improved support for systems such as CHERI with extra data stored in pointers
(`#2932 `_).
Thanks `@davidchisnall (David Chisnall) `_.
* Improved documentation
(`#2706 `_,
`#2712 `_,
`#2789 `_,
`#2803 `_,
`#2805 `_,
`#2815 `_,
`#2924 `_).
Thanks `@BRevzin (Barry Revzin) `_,
`@Pokechu22 `_,
`@setoye (Alta) `_,
`@rtobar `_,
`@rbrugo (Riccardo Brugo) `_,
`@anoonD (cre) `_,
`@leha-bot (Alex) `_.
* Improved build configuration
(`#2766 `_,
`#2772 `_,
`#2836 `_,
`#2852 `_,
`#2907 `_,
`#2913 `_,
`#2914 `_).
Thanks `@kambala-decapitator (Andrey Filipenkov)
`_,
`@mattiasljungstrom (Mattias Ljungström)
`_,
`@kieselnb (Nick Kiesel) `_,
`@nathannaveen `_,
`@Vertexwahn `_.
* Fixed various warnings and compilation issues
(`#2408 `_,
`#2507 `_,
`#2697 `_,
`#2715 `_,
`#2717 `_,
`#2722 `_,
`#2724 `_,
`#2725 `_,
`#2726 `_,
`#2728 `_,
`#2732 `_,
`#2738 `_,
`#2742 `_,
`#2744 `_,
`#2745 `_,
`#2746 `_,
`#2754 `_,
`#2755 `_,
`#2757 `_,
`#2758 `_,
`#2761 `_,
`#2762 `_,
`#2763 `_,
`#2765 `_,
`#2769 `_,
`#2770 `_,
`#2771 `_,
`#2777 `_,
`#2779 `_,
`#2782 `_,
`#2783 `_,
`#2794 `_,
`#2796 `_,
`#2797 `_,
`#2801 `_,
`#2802 `_,
`#2808 `_,
`#2818 `_,
`#2819 `_,
`#2829 `_,
`#2835 `_,
`#2848 `_,
`#2860 `_,
`#2861 `_,
`#2882 `_,
`#2886 `_,
`#2891 `_,
`#2892 `_,
`#2895 `_,
`#2896 `_,
`#2903 `_,
`#2906 `_,
`#2908 `_,
`#2909 `_,
`#2920 `_,
`#2922 `_,
`#2927 `_,
`#2929 `_,
`#2936 `_,
`#2937 `_,
`#2938 `_,
`#2951 `_,
`#2954 `_,
`#2957 `_,
`#2958 `_,
`#2960 `_).
Thanks `@matrackif `_
`@Tobi823 (Tobias Hellmann) `_,
`@ivan-volnov (Ivan Volnov) `_,
`@VasiliPupkin256 `_,
`@federico-busato (Federico) `_,
`@barcharcraz (Charlie Barto) `_,
`@jk-jeon (Junekey Jeon) `_,
`@HazardyKnusperkeks (Björn Schäpers)
`_,
`@dalboris (Boris Dalstein) `_,
`@seanm (Sean McBride) `_,
`@gsjaardema (Greg Sjaardema) `_,
`@timsong-cpp `_,
`@seanm (Sean McBride) `_,
`@frithrah `_,
`@chronoxor (Ivan Shynkarenka) `_,
`@Agga