From 8877ad72fa34a316f875e00104d0672895705021 Mon Sep 17 00:00:00 2001 From: Jett Date: Sun, 16 Oct 2016 17:14:27 -0500 Subject: [PATCH] remove whitespace loop in strtox --- src/json.hpp | 18 ------------------ src/json.hpp.re2c | 18 ------------------ 2 files changed, 36 deletions(-) diff --git a/src/json.hpp b/src/json.hpp index 59b69294c..143ac5732 100644 --- a/src/json.hpp +++ b/src/json.hpp @@ -8800,18 +8800,6 @@ basic_json_parser_63: return result; } - // non locale aware isspace - bool nl_isspace(const char c) const - { - return - c == 0x20 or - c == 0x09 or - c == 0x0a or - c == 0x0b or - c == 0x0c or - c == 0x0d; - } - // non locale aware isdigit // Microsoft in 1252 codepage and others may classify additional single-byte characters as digits using std::isdigit bool nl_isdigit(const char c) const @@ -8845,12 +8833,6 @@ basic_json_parser_63: T result = 0; const char *fst = st; bool successful_parse = false; - - while (nl_isspace(*fst)) - { - ++fst; - } - char cp = *fst; int exp = 0; // exponent { diff --git a/src/json.hpp.re2c b/src/json.hpp.re2c index 911c6e5fd..4f29a79e2 100644 --- a/src/json.hpp.re2c +++ b/src/json.hpp.re2c @@ -8097,18 +8097,6 @@ class basic_json return result; } - // non locale aware isspace - bool nl_isspace(const char c) const - { - return - c == 0x20 or - c == 0x09 or - c == 0x0a or - c == 0x0b or - c == 0x0c or - c == 0x0d; - } - // non locale aware isdigit // Microsoft in 1252 codepage and others may classify additional single-byte characters as digits using std::isdigit bool nl_isdigit(const char c) const @@ -8142,12 +8130,6 @@ class basic_json T result = 0; const char *fst = st; bool successful_parse = false; - - while (nl_isspace(*fst)) - { - ++fst; - } - char cp = *fst; int exp = 0; // exponent {