mirror of
https://github.com/fastfloat/fast_float.git
synced 2025-12-07 01:06:48 +08:00
fix for the parse_number_string
This commit is contained in:
parent
3ee80c2da3
commit
88fff01513
@ -396,14 +396,14 @@ parse_number_string(UC const *p, UC const *pend,
|
|||||||
// Now we can parse the explicit exponential part.
|
// Now we can parse the explicit exponential part.
|
||||||
am_pow_t exp_number = 0; // explicit exponential part
|
am_pow_t exp_number = 0; // explicit exponential part
|
||||||
if ((p != pend) &&
|
if ((p != pend) &&
|
||||||
(chars_format_t(options.format & chars_format::scientific) &&
|
(chars_format_t(options.format & chars_format::scientific) &&
|
||||||
((UC('e') == *p) || (UC('E') == *p)))
|
((UC('e') == *p) || (UC('E') == *p))
|
||||||
#ifndef FASTFLOAT_ONLY_POSITIVE_C_NUMBER_WO_INF_NAN
|
#ifndef FASTFLOAT_ONLY_POSITIVE_C_NUMBER_WO_INF_NAN
|
||||||
|| (chars_format_t(options.format & detail::basic_fortran_fmt) &&
|
|| (chars_format_t(options.format & detail::basic_fortran_fmt) &&
|
||||||
((UC('+') == *p) || (UC('-') == *p) || (UC('d') == *p) ||
|
((UC('+') == *p) || (UC('-') == *p) || (UC('d') == *p) ||
|
||||||
(UC('D') == *p)))
|
(UC('D') == *p)))
|
||||||
#endif
|
#endif
|
||||||
) {
|
)) {
|
||||||
UC const *location_of_e = p;
|
UC const *location_of_e = p;
|
||||||
#ifdef FASTFLOAT_ONLY_POSITIVE_C_NUMBER_WO_INF_NAN
|
#ifdef FASTFLOAT_ONLY_POSITIVE_C_NUMBER_WO_INF_NAN
|
||||||
++p;
|
++p;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user