mirror of
https://github.com/fastfloat/fast_float.git
synced 2025-12-07 01:06:48 +08:00
Completely remove deprecated macroses FASTFLOAT_ALLOWS_LEADING_PLUS and FASTFLOAT_SKIP_WHITE_SPACE, please use options.
Compilation fix when FASTFLOAT_ONLY_POSITIVE_C_NUMBER_WO_INF_NAN isn't defined.
This commit is contained in:
parent
ae29a0dbe5
commit
f496321570
@ -72,15 +72,7 @@ template <typename UC> struct parse_options_t {
|
|||||||
: format(fmt), decimal_point(dot), base(static_cast<uint8_t>(b)) {}
|
: format(fmt), decimal_point(dot), base(static_cast<uint8_t>(b)) {}
|
||||||
|
|
||||||
/** Which number formats are accepted */
|
/** Which number formats are accepted */
|
||||||
const chars_format format
|
const chars_format format;
|
||||||
// adjust for deprecated feature macros
|
|
||||||
#ifdef FASTFLOAT_ALLOWS_LEADING_PLUS
|
|
||||||
| chars_format::allow_leading_plus
|
|
||||||
#endif
|
|
||||||
#ifdef FASTFLOAT_SKIP_WHITE_SPACE
|
|
||||||
| chars_format::skip_white_space
|
|
||||||
#endif
|
|
||||||
;
|
|
||||||
/** The character used as decimal point */
|
/** The character used as decimal point */
|
||||||
const UC decimal_point;
|
const UC decimal_point;
|
||||||
/** The base used for integers */
|
/** The base used for integers */
|
||||||
|
|||||||
@ -378,7 +378,7 @@ from_chars_int_advanced(UC const *first, UC const *last, T &value,
|
|||||||
#endif
|
#endif
|
||||||
if (
|
if (
|
||||||
#ifndef FASTFLOAT_ONLY_POSITIVE_C_NUMBER_WO_INF_NAN
|
#ifndef FASTFLOAT_ONLY_POSITIVE_C_NUMBER_WO_INF_NAN
|
||||||
first == last
|
first == last ||
|
||||||
#endif
|
#endif
|
||||||
options.base < 2 || options.base > 36) {
|
options.base < 2 || options.base > 36) {
|
||||||
from_chars_result_t<UC> answer;
|
from_chars_result_t<UC> answer;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user