From 140316960788cada7ae0244570b87cb90531d663 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=9E=AC=EC=9A=B1?= Date: Tue, 24 Feb 2026 11:00:24 +0900 Subject: [PATCH] Implement digit separator skipping in exponent parsing --- include/fast_float/ascii_number.h | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/include/fast_float/ascii_number.h b/include/fast_float/ascii_number.h index c78fd2a..2de0c4c 100644 --- a/include/fast_float/ascii_number.h +++ b/include/fast_float/ascii_number.h @@ -463,7 +463,14 @@ parse_number_string(UC const *p, UC const *pend, // Otherwise, we will be ignoring the 'e'. p = location_of_e; } else { - while ((p != pend) && is_integer(*p)) { + while (p != pend) { + if (has_separator && *p == separator) { + ++p; + continue; + } + if (!is_integer(*p)) { + break; + } uint8_t digit = uint8_t(*p - UC('0')); if (exp_number < 0x10000000) { exp_number = 10 * exp_number + digit;