aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2023-08-07 14:06:59 +0100
committerJonathan Wakely <jwakely@redhat.com>2023-08-17 20:24:18 +0100
commit6cf214b4fc97f5320fff8f4d5d262ef858f34a8d (patch)
tree60a765a4b888c5e37831ebfc3cc20f5680f4ded3 /gcc
parent1a566fddea212a6a8e4484f7843d8e5d39b5bff0 (diff)
downloadgcc-6cf214b4fc97f5320fff8f4d5d262ef858f34a8d.zip
gcc-6cf214b4fc97f5320fff8f4d5d262ef858f34a8d.tar.gz
gcc-6cf214b4fc97f5320fff8f4d5d262ef858f34a8d.tar.bz2
libstdc++: Add std::formatter specializations for extended float types
This makes it possible to format _Float32, _Float64 etc. in C++20 mode. Previously it was only possible to format them in C++23 when the <stdfloat> typedefs and the std::to_chars overloads were defined. Instead of relying on std::to_chars for those types, we can just reuse the formatters for float, double and long double. This also avoids template bloat by reusing the same specializations instead of instantiating __formatter_fp for every different type. libstdc++-v3/ChangeLog: * include/std/format (formatter): Add partial specializations for extended floating-point types. * testsuite/std/format/functions/format.cc: Move test_float128() to ... * testsuite/std/format/formatter/ext_float.cc: New test.
Diffstat (limited to 'gcc')
0 files changed, 0 insertions, 0 deletions