Skip to content
Snippets Groups Projects
Commit dfc1ea41 authored by Jonathan Wakely's avatar Jonathan Wakely
Browse files

libstdc++: Replace std::isdigit and std::isxdigit in <format> [PR107817]

These functions aren't usable in constant expressions. Provide our own
implementations, based on __from_chars_alnum_to_val from <charconv>.

libstdc++-v3/ChangeLog:

	PR libstdc++/107817
	* include/std/charconv (__from_chars_alnum_to_val): Add
	constexpr for C++20.
	* include/std/format (__is_digit, __is_xdigit): New functions.
	(_Spec::_S_parse_width_or_precision): Use __is_digit.
	(__formatter_fp::parse): Use __is_xdigit.
parent 6b859736
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment