Skip to content

Commit

Permalink
fix csubstr.first_real_span() when the exponent only has one digit
Browse files Browse the repository at this point in the history
  • Loading branch information
biojppm committed Mar 28, 2024
1 parent 51126b3 commit fae7106
Show file tree
Hide file tree
Showing 2 changed files with 287 additions and 10 deletions.
15 changes: 6 additions & 9 deletions src/c4/substr.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -1211,7 +1211,7 @@ struct C4CORE_EXPORT basic_substring
basic_substring ne = first_non_empty_span();
if(ne.empty())
return ne;
size_t skip_start = (ne.str[0] == '+' || ne.str[0] == '-');
const size_t skip_start = (ne.str[0] == '+' || ne.str[0] == '-');
C4_ASSERT(skip_start == 0 || skip_start == 1);
// if we have at least three digits after the leading sign, it
// can be decimal, or hex, or bin or oct. Ex:
Expand Down Expand Up @@ -1351,14 +1351,11 @@ struct C4CORE_EXPORT basic_substring
power_part_dec:
C4_ASSERT(pos > 0);
C4_ASSERT(str[pos - 1] == 'e' || str[pos - 1] == 'E');
// either a + or a - is expected here, followed by more chars.
// also, using (pos+1) in this check will cause an early
// return when no more chars follow the sign.
if(len <= (pos+1) || ((!intchars) && (!fracchars)))
// either digits, or +, or - are expected here, followed by more digits.
if((len == pos) || ((!intchars) && (!fracchars)))
return first(0);
++pos; // this was the sign.
// ... so the (pos+1) ensures that we enter the loop and
// hence that there exist chars in the power part
if(str[pos] == '-' || str[pos] == '+')
++pos; // skip the sign
powchars = false;
for( ; pos < len; ++pos)
{
Expand All @@ -1370,7 +1367,7 @@ struct C4CORE_EXPORT basic_substring
else
return first(0);
}
return *this;
return powchars ? *this : first(0);
}

// this function is declared inside the class to avoid a VS error with __declspec(dllimport)
Expand Down
282 changes: 281 additions & 1 deletion test/test_substr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1711,6 +1711,20 @@ TEST_CASE("substr.first_real_span")
CHECK_EQ(csubstr("0").first_real_span(), "0");
CHECK_EQ(csubstr("+0").first_real_span(), "+0");
CHECK_EQ(csubstr("-0").first_real_span(), "-0");
CHECK_EQ(csubstr("1.").first_real_span(), "1.");
CHECK_EQ(csubstr("+1.").first_real_span(), "+1.");
CHECK_EQ(csubstr("-1.").first_real_span(), "-1.");
CHECK_EQ(csubstr("-0.").first_real_span(), "-0.");
CHECK_EQ(csubstr("0.").first_real_span(), "0.");
CHECK_EQ(csubstr("+0.").first_real_span(), "+0.");
CHECK_EQ(csubstr("-0.").first_real_span(), "-0.");
CHECK_EQ(csubstr("1.2").first_real_span(), "1.2");
CHECK_EQ(csubstr("+1.2").first_real_span(), "+1.2");
CHECK_EQ(csubstr("-1.2").first_real_span(), "-1.2");
CHECK_EQ(csubstr("-0.2").first_real_span(), "-0.2");
CHECK_EQ(csubstr("0.2").first_real_span(), "0.2");
CHECK_EQ(csubstr("+0.2").first_real_span(), "+0.2");
CHECK_EQ(csubstr("-0.2").first_real_span(), "-0.2");
CHECK_EQ(csubstr("1234 abc").first_real_span(), "1234");
CHECK_EQ(csubstr("abc 1234 abc").first_real_span(), "");
CHECK_EQ(csubstr("+0x1234 abc").first_real_span(), "+0x1234");
Expand Down Expand Up @@ -1755,15 +1769,120 @@ TEST_CASE("substr.first_real_span")
CHECK_EQ(csubstr("+0o").first_real_span(), "");
CHECK_EQ(csubstr("-0o").first_real_span(), "");
CHECK_EQ(csubstr("-1.234 asdkjh").first_real_span(), "-1.234");
// CHECK_EQ(csubstr("-1.234e5 asdkjh").first_real_span(), "-1.234e5");
CHECK_EQ(csubstr("-1.234e5 asdkjh").first_real_span(), "-1.234e5");
CHECK_EQ(csubstr("-1.234E5 asdkjh").first_real_span(), "-1.234E5");
CHECK_EQ(csubstr("-1.234e+5 asdkjh").first_real_span(), "-1.234e+5");
CHECK_EQ(csubstr("-1.234E+5 asdkjh").first_real_span(), "-1.234E+5");
CHECK_EQ(csubstr("-1.234e-5 asdkjh").first_real_span(), "-1.234e-5");
CHECK_EQ(csubstr("-1.234E-5 asdkjh").first_real_span(), "-1.234E-5");
CHECK_EQ(csubstr("9.5e7 asdkjh").first_real_span(), "9.5e7");
CHECK_EQ(csubstr("9.5E7 asdkjh").first_real_span(), "9.5E7");
CHECK_EQ(csubstr("9.5e+7 asdkjh").first_real_span(), "9.5e+7");
CHECK_EQ(csubstr("9.5E+7 asdkjh").first_real_span(), "9.5E+7");
CHECK_EQ(csubstr("9.5e-7 asdkjh").first_real_span(), "9.5e-7");
CHECK_EQ(csubstr("9.5E-7 asdkjh").first_real_span(), "9.5E-7");
CHECK_EQ(csubstr("-9.5e7 asdkjh").first_real_span(), "-9.5e7");
CHECK_EQ(csubstr("-9.5E7 asdkjh").first_real_span(), "-9.5E7");
CHECK_EQ(csubstr("-9.5e+7 asdkjh").first_real_span(), "-9.5e+7");
CHECK_EQ(csubstr("-9.5E+7 asdkjh").first_real_span(), "-9.5E+7");
CHECK_EQ(csubstr("-9.5e-7 asdkjh").first_real_span(), "-9.5e-7");
CHECK_EQ(csubstr("-9.5E-7 asdkjh").first_real_span(), "-9.5E-7");
CHECK_EQ(csubstr("+9.5e7 asdkjh").first_real_span(), "+9.5e7");
CHECK_EQ(csubstr("+9.5E7 asdkjh").first_real_span(), "+9.5E7");
CHECK_EQ(csubstr("+9.5e+7 asdkjh").first_real_span(), "+9.5e+7");
CHECK_EQ(csubstr("+9.5E+7 asdkjh").first_real_span(), "+9.5E+7");
CHECK_EQ(csubstr("+9.5e-7 asdkjh").first_real_span(), "+9.5e-7");
CHECK_EQ(csubstr("+9.5E-7 asdkjh").first_real_span(), "+9.5E-7");
CHECK_EQ(csubstr("9.5e17 asdkjh").first_real_span(), "9.5e17");
CHECK_EQ(csubstr("9.5E17 asdkjh").first_real_span(), "9.5E17");
CHECK_EQ(csubstr("9.5e+17 asdkjh").first_real_span(), "9.5e+17");
CHECK_EQ(csubstr("9.5E+17 asdkjh").first_real_span(), "9.5E+17");
CHECK_EQ(csubstr("9.5e-17 asdkjh").first_real_span(), "9.5e-17");
CHECK_EQ(csubstr("9.5E-17 asdkjh").first_real_span(), "9.5E-17");
CHECK_EQ(csubstr("-9.5e17 asdkjh").first_real_span(), "-9.5e17");
CHECK_EQ(csubstr("-9.5E17 asdkjh").first_real_span(), "-9.5E17");
CHECK_EQ(csubstr("-9.5e+17 asdkjh").first_real_span(), "-9.5e+17");
CHECK_EQ(csubstr("-9.5E+17 asdkjh").first_real_span(), "-9.5E+17");
CHECK_EQ(csubstr("-9.5e-17 asdkjh").first_real_span(), "-9.5e-17");
CHECK_EQ(csubstr("-9.5E-17 asdkjh").first_real_span(), "-9.5E-17");
CHECK_EQ(csubstr("+9.5e17 asdkjh").first_real_span(), "+9.5e17");
CHECK_EQ(csubstr("+9.5E17 asdkjh").first_real_span(), "+9.5E17");
CHECK_EQ(csubstr("+9.5e+17 asdkjh").first_real_span(), "+9.5e+17");
CHECK_EQ(csubstr("+9.5E+17 asdkjh").first_real_span(), "+9.5E+17");
CHECK_EQ(csubstr("+9.5e-17 asdkjh").first_real_span(), "+9.5e-17");
CHECK_EQ(csubstr("+9.5E-17 asdkjh").first_real_span(), "+9.5E-17");
CHECK_EQ(csubstr("129.532e7 asdkjh").first_real_span(), "129.532e7");
CHECK_EQ(csubstr("129.532E7 asdkjh").first_real_span(), "129.532E7");
CHECK_EQ(csubstr("129.532e+7 asdkjh").first_real_span(), "129.532e+7");
CHECK_EQ(csubstr("129.532E+7 asdkjh").first_real_span(), "129.532E+7");
CHECK_EQ(csubstr("129.532e-7 asdkjh").first_real_span(), "129.532e-7");
CHECK_EQ(csubstr("129.532E-7 asdkjh").first_real_span(), "129.532E-7");
CHECK_EQ(csubstr("-129.532e7 asdkjh").first_real_span(), "-129.532e7");
CHECK_EQ(csubstr("-129.532E7 asdkjh").first_real_span(), "-129.532E7");
CHECK_EQ(csubstr("-129.532e+7 asdkjh").first_real_span(), "-129.532e+7");
CHECK_EQ(csubstr("-129.532E+7 asdkjh").first_real_span(), "-129.532E+7");
CHECK_EQ(csubstr("-129.532e-7 asdkjh").first_real_span(), "-129.532e-7");
CHECK_EQ(csubstr("-129.532E-7 asdkjh").first_real_span(), "-129.532E-7");
CHECK_EQ(csubstr("+129.532e7 asdkjh").first_real_span(), "+129.532e7");
CHECK_EQ(csubstr("+129.532E7 asdkjh").first_real_span(), "+129.532E7");
CHECK_EQ(csubstr("+129.532e+7 asdkjh").first_real_span(), "+129.532e+7");
CHECK_EQ(csubstr("+129.532E+7 asdkjh").first_real_span(), "+129.532E+7");
CHECK_EQ(csubstr("+129.532e-7 asdkjh").first_real_span(), "+129.532e-7");
CHECK_EQ(csubstr("+129.532E-7 asdkjh").first_real_span(), "+129.532E-7");
CHECK_EQ(csubstr("129.532e17 asdkjh").first_real_span(), "129.532e17");
CHECK_EQ(csubstr("129.532E17 asdkjh").first_real_span(), "129.532E17");
CHECK_EQ(csubstr("129.532e+17 asdkjh").first_real_span(), "129.532e+17");
CHECK_EQ(csubstr("129.532E+17 asdkjh").first_real_span(), "129.532E+17");
CHECK_EQ(csubstr("129.532e-17 asdkjh").first_real_span(), "129.532e-17");
CHECK_EQ(csubstr("129.532E-17 asdkjh").first_real_span(), "129.532E-17");
CHECK_EQ(csubstr("-129.532e17 asdkjh").first_real_span(), "-129.532e17");
CHECK_EQ(csubstr("-129.532E17 asdkjh").first_real_span(), "-129.532E17");
CHECK_EQ(csubstr("-129.532e+17 asdkjh").first_real_span(), "-129.532e+17");
CHECK_EQ(csubstr("-129.532E+17 asdkjh").first_real_span(), "-129.532E+17");
CHECK_EQ(csubstr("-129.532e-17 asdkjh").first_real_span(), "-129.532e-17");
CHECK_EQ(csubstr("-129.532E-17 asdkjh").first_real_span(), "-129.532E-17");
CHECK_EQ(csubstr("+129.532e17 asdkjh").first_real_span(), "+129.532e17");
CHECK_EQ(csubstr("+129.532E17 asdkjh").first_real_span(), "+129.532E17");
CHECK_EQ(csubstr("+129.532e+17 asdkjh").first_real_span(), "+129.532e+17");
CHECK_EQ(csubstr("+129.532E+17 asdkjh").first_real_span(), "+129.532E+17");
CHECK_EQ(csubstr("+129.532e-17 asdkjh").first_real_span(), "+129.532e-17");
CHECK_EQ(csubstr("+129.532E-17 asdkjh").first_real_span(), "+129.532E-17");
CHECK_EQ(csubstr("129.532e asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("129.532E asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("129.532e+ asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("129.532E+ asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("129.532e- asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("129.532E- asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("-129.532e asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("-129.532E asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("-129.532e+ asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("-129.532E+ asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("-129.532e- asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("-129.532E- asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("+129.532e asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("+129.532E asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("+129.532e+ asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("+129.532E+ asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("+129.532e- asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("+129.532E- asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("0x1.e8480p+19 asdkjh").first_real_span(), "0x1.e8480p+19");
CHECK_EQ(csubstr("0x1.e8480p-19 asdkjh").first_real_span(), "0x1.e8480p-19");
CHECK_EQ(csubstr("-0x1.e8480p+19 asdkjh").first_real_span(), "-0x1.e8480p+19");
CHECK_EQ(csubstr("-0x1.e8480p-19 asdkjh").first_real_span(), "-0x1.e8480p-19");
CHECK_EQ(csubstr("+0x1.e8480p+19 asdkjh").first_real_span(), "+0x1.e8480p+19");
CHECK_EQ(csubstr("+0x1.e8480p-19 asdkjh").first_real_span(), "+0x1.e8480p-19");
CHECK_EQ(csubstr("0x1.e8480p+1 asdkjh").first_real_span(), "0x1.e8480p+1");
CHECK_EQ(csubstr("0x1.e8480p-1 asdkjh").first_real_span(), "0x1.e8480p-1");
CHECK_EQ(csubstr("-0x1.e8480p+1 asdkjh").first_real_span(), "-0x1.e8480p+1");
CHECK_EQ(csubstr("-0x1.e8480p-1 asdkjh").first_real_span(), "-0x1.e8480p-1");
CHECK_EQ(csubstr("+0x1.e8480p+1 asdkjh").first_real_span(), "+0x1.e8480p+1");
CHECK_EQ(csubstr("+0x1.e8480p-1 asdkjh").first_real_span(), "+0x1.e8480p-1");
CHECK_EQ(csubstr("0x1.e8480p+ asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("0x1.e8480p- asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("-0x1.e8480p+ asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("-0x1.e8480p- asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("+0x1.e8480p+ asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("+0x1.e8480p- asdkjh").first_real_span(), "");
CHECK_EQ(csubstr("infinity").first_real_span(), "infinity");
CHECK_EQ(csubstr(" infinity").first_real_span(), "infinity");
CHECK_EQ(csubstr("-infinity").first_real_span(), "-infinity");
Expand Down Expand Up @@ -2210,6 +2329,88 @@ TEST_CASE("substr.is_real")
CHECK_UNARY(csubstr("0.1").is_real());
CHECK_UNARY(csubstr("-0.1").is_real());
}
SUBCASE("scientific")
{
CHECK_UNARY(csubstr("-1.234").is_real());
CHECK_UNARY(csubstr("-1.234e5").is_real());
CHECK_UNARY(csubstr("-1.234E5").is_real());
CHECK_UNARY(csubstr("-1.234e+5").is_real());
CHECK_UNARY(csubstr("-1.234E+5").is_real());
CHECK_UNARY(csubstr("-1.234e-5").is_real());
CHECK_UNARY(csubstr("-1.234E-5").is_real());
CHECK_UNARY(csubstr("9.5e7").is_real());
CHECK_UNARY(csubstr("9.5E7").is_real());
CHECK_UNARY(csubstr("9.5e+7").is_real());
CHECK_UNARY(csubstr("9.5E+7").is_real());
CHECK_UNARY(csubstr("9.5e-7").is_real());
CHECK_UNARY(csubstr("9.5E-7").is_real());
CHECK_UNARY(csubstr("-9.5e7").is_real());
CHECK_UNARY(csubstr("-9.5E7").is_real());
CHECK_UNARY(csubstr("-9.5e+7").is_real());
CHECK_UNARY(csubstr("-9.5E+7").is_real());
CHECK_UNARY(csubstr("-9.5e-7").is_real());
CHECK_UNARY(csubstr("-9.5E-7").is_real());
CHECK_UNARY(csubstr("+9.5e7").is_real());
CHECK_UNARY(csubstr("+9.5E7").is_real());
CHECK_UNARY(csubstr("+9.5e+7").is_real());
CHECK_UNARY(csubstr("+9.5E+7").is_real());
CHECK_UNARY(csubstr("+9.5e-7").is_real());
CHECK_UNARY(csubstr("+9.5E-7").is_real());
CHECK_UNARY(csubstr("9.5e17").is_real());
CHECK_UNARY(csubstr("9.5E17").is_real());
CHECK_UNARY(csubstr("9.5e+17").is_real());
CHECK_UNARY(csubstr("9.5E+17").is_real());
CHECK_UNARY(csubstr("9.5e-17").is_real());
CHECK_UNARY(csubstr("9.5E-17").is_real());
CHECK_UNARY(csubstr("-9.5e17").is_real());
CHECK_UNARY(csubstr("-9.5E17").is_real());
CHECK_UNARY(csubstr("-9.5e+17").is_real());
CHECK_UNARY(csubstr("-9.5E+17").is_real());
CHECK_UNARY(csubstr("-9.5e-17").is_real());
CHECK_UNARY(csubstr("-9.5E-17").is_real());
CHECK_UNARY(csubstr("+9.5e17").is_real());
CHECK_UNARY(csubstr("+9.5E17").is_real());
CHECK_UNARY(csubstr("+9.5e+17").is_real());
CHECK_UNARY(csubstr("+9.5E+17").is_real());
CHECK_UNARY(csubstr("+9.5e-17").is_real());
CHECK_UNARY(csubstr("+9.5E-17").is_real());
CHECK_UNARY(csubstr("129.532e7").is_real());
CHECK_UNARY(csubstr("129.532E7").is_real());
CHECK_UNARY(csubstr("129.532e+7").is_real());
CHECK_UNARY(csubstr("129.532E+7").is_real());
CHECK_UNARY(csubstr("129.532e-7").is_real());
CHECK_UNARY(csubstr("129.532E-7").is_real());
CHECK_UNARY(csubstr("-129.532e7").is_real());
CHECK_UNARY(csubstr("-129.532E7").is_real());
CHECK_UNARY(csubstr("-129.532e+7").is_real());
CHECK_UNARY(csubstr("-129.532E+7").is_real());
CHECK_UNARY(csubstr("-129.532e-7").is_real());
CHECK_UNARY(csubstr("-129.532E-7").is_real());
CHECK_UNARY(csubstr("+129.532e7").is_real());
CHECK_UNARY(csubstr("+129.532E7").is_real());
CHECK_UNARY(csubstr("+129.532e+7").is_real());
CHECK_UNARY(csubstr("+129.532E+7").is_real());
CHECK_UNARY(csubstr("+129.532e-7").is_real());
CHECK_UNARY(csubstr("+129.532E-7").is_real());
CHECK_UNARY(csubstr("129.532e17").is_real());
CHECK_UNARY(csubstr("129.532E17").is_real());
CHECK_UNARY(csubstr("129.532e+17").is_real());
CHECK_UNARY(csubstr("129.532E+17").is_real());
CHECK_UNARY(csubstr("129.532e-17").is_real());
CHECK_UNARY(csubstr("129.532E-17").is_real());
CHECK_UNARY(csubstr("-129.532e17").is_real());
CHECK_UNARY(csubstr("-129.532E17").is_real());
CHECK_UNARY(csubstr("-129.532e+17").is_real());
CHECK_UNARY(csubstr("-129.532E+17").is_real());
CHECK_UNARY(csubstr("-129.532e-17").is_real());
CHECK_UNARY(csubstr("-129.532E-17").is_real());
CHECK_UNARY(csubstr("+129.532e17").is_real());
CHECK_UNARY(csubstr("+129.532E17").is_real());
CHECK_UNARY(csubstr("+129.532e+17").is_real());
CHECK_UNARY(csubstr("+129.532E+17").is_real());
CHECK_UNARY(csubstr("+129.532e-17").is_real());
CHECK_UNARY(csubstr("+129.532E-17").is_real());
}
SUBCASE("hexadecimal")
{
CHECK_FALSE(csubstr("0x").is_real());
Expand Down Expand Up @@ -2637,6 +2838,85 @@ const number numbers[] = {
{"infinity", kIsReal},
{"inf", kIsReal},
{"nan", kIsReal},
{"-1.234", kIsReal},
{"-1.234e5", kIsReal},
{"-1.234E5", kIsReal},
{"-1.234e+5", kIsReal},
{"-1.234E+5", kIsReal},
{"-1.234e-5", kIsReal},
{"-1.234E-5", kIsReal},
{"9.5e7", kIsReal},
{"9.5E7", kIsReal},
{"9.5e+7", kIsReal},
{"9.5E+7", kIsReal},
{"9.5e-7", kIsReal},
{"9.5E-7", kIsReal},
{"-9.5e7", kIsReal},
{"-9.5E7", kIsReal},
{"-9.5e+7", kIsReal},
{"-9.5E+7", kIsReal},
{"-9.5e-7", kIsReal},
{"-9.5E-7", kIsReal},
{"+9.5e7", kIsReal},
{"+9.5E7", kIsReal},
{"+9.5e+7", kIsReal},
{"+9.5E+7", kIsReal},
{"+9.5e-7", kIsReal},
{"+9.5E-7", kIsReal},
{"9.5e17", kIsReal},
{"9.5E17", kIsReal},
{"9.5e+17", kIsReal},
{"9.5E+17", kIsReal},
{"9.5e-17", kIsReal},
{"9.5E-17", kIsReal},
{"-9.5e17", kIsReal},
{"-9.5E17", kIsReal},
{"-9.5e+17", kIsReal},
{"-9.5E+17", kIsReal},
{"-9.5e-17", kIsReal},
{"-9.5E-17", kIsReal},
{"+9.5e17", kIsReal},
{"+9.5E17", kIsReal},
{"+9.5e+17", kIsReal},
{"+9.5E+17", kIsReal},
{"+9.5e-17", kIsReal},
{"+9.5E-17", kIsReal},
{"129.532e7", kIsReal},
{"129.532E7", kIsReal},
{"129.532e+7", kIsReal},
{"129.532E+7", kIsReal},
{"129.532e-7", kIsReal},
{"129.532E-7", kIsReal},
{"-129.532e7", kIsReal},
{"-129.532E7", kIsReal},
{"-129.532e+7", kIsReal},
{"-129.532E+7", kIsReal},
{"-129.532e-7", kIsReal},
{"-129.532E-7", kIsReal},
{"+129.532e7", kIsReal},
{"+129.532E7", kIsReal},
{"+129.532e+7", kIsReal},
{"+129.532E+7", kIsReal},
{"+129.532e-7", kIsReal},
{"+129.532E-7", kIsReal},
{"129.532e17", kIsReal},
{"129.532E17", kIsReal},
{"129.532e+17", kIsReal},
{"129.532E+17", kIsReal},
{"129.532e-17", kIsReal},
{"129.532E-17", kIsReal},
{"-129.532e17", kIsReal},
{"-129.532E17", kIsReal},
{"-129.532e+17", kIsReal},
{"-129.532E+17", kIsReal},
{"-129.532e-17", kIsReal},
{"-129.532E-17", kIsReal},
{"+129.532e17", kIsReal},
{"+129.532E17", kIsReal},
{"+129.532e+17", kIsReal},
{"+129.532E+17", kIsReal},
{"+129.532e-17", kIsReal},
{"+129.532E-17", kIsReal},
};

TEST_CASE("substr.is_number")
Expand Down

0 comments on commit fae7106

Please sign in to comment.