17 Jan
2024
17 Jan
'24
12:13 p.m.
On 1/17/24 14:57, Matt Borland via Boost wrote:
But isn't strtold locale dependent while from_chars is supposed to act as-if strtod in the "C"-locale? Wouldn't that fallback violate that contract on non-English locales?
Or does that fallback only apply when the locale difference does not matter?
Alex
The latter since we will have already attempted conversion internally, and rejected a string that is not in the "C"-locale.
Is strtod operating in non-C locale required to correctly parse a number that was formatted using C locale? For example, what if it expects a fractional digits separator other than dot?