From 8a990cc9d6b5d323f7bfd9ae70c92a6571b7269e Mon Sep 17 00:00:00 2001 From: Mykola Bilochub Date: Sat, 22 Jul 2017 14:43:08 +0300 Subject: [PATCH 1/3] src: fix building on the old gcc versions --- .travis.yml | 40 +++------------------------------------- src/parser.cc | 6 ++---- 2 files changed, 5 insertions(+), 41 deletions(-) diff --git a/.travis.yml b/.travis.yml index 1dd86bc4..8fbfe284 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,41 +1,7 @@ language: node_js node_js: - - "6.0" - - "6.1" - - "6.2" - - "6.3" - - "6.4" - - "6.5" - - "6.6" - - "6.7" - - "6.8" - - "6.9" - - "6.10" - - "6.11" - - "7.0" - - "7.1" - - "7.2" - - "7.3" - - "7.4" - - "7.5" - - "7.6" - - "7.7" - - "7.8" - - "7.9" - - "7.10" - - "8.0" - - "8.1" -env: - - CXX=g++-6 -addons: - apt: - sources: - - ubuntu-toolchain-r-test - packages: - - g++-6 - firefox: latest -before_script: - - export DISPLAY=:99.0 - - sh -e /etc/init.d/xvfb start + - 6 + - 7 + - 8 script: - npm test diff --git a/src/parser.cc b/src/parser.cc index 678a89a4..905de4fd 100644 --- a/src/parser.cc +++ b/src/parser.cc @@ -21,8 +21,6 @@ using std::function; using std::isalnum; using std::isalpha; using std::isdigit; -using std::isinf; -using std::isnan; using std::isxdigit; using std::memcpy; using std::memset; @@ -359,12 +357,12 @@ MaybeLocal ParseDecimalNumber(Isolate* isolate, } // strictly allow only "NaN" and "Infinity" - if (isnan(number)) { + if (std::isnan(number)) { if (strncmp(begin + 1, "aN", 2) != 0) { THROW_EXCEPTION(SyntaxError, "Invalid format: expected NaN"); return MaybeLocal(); } - } else if (isinf(number)) { + } else if (std::isinf(number)) { if (strncmp(begin + 1, "nfinity", 7) != 0) { THROW_EXCEPTION(SyntaxError, "Invalid format: expected Infinity"); return MaybeLocal(); From b826b28dc4365d42a5a8e38bfb851fe2001f67fb Mon Sep 17 00:00:00 2001 From: Mykola Bilochub Date: Sat, 22 Jul 2017 14:47:26 +0300 Subject: [PATCH 2/3] fixup! src: fix building on the old gcc versions --- .travis.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.travis.yml b/.travis.yml index 8fbfe284..d078d394 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,5 +3,7 @@ node_js: - 6 - 7 - 8 +dist: trusty +sudo: false script: - npm test From 0a8fb45d24bec7c404e05a3e2cbbf2fad6b49cbe Mon Sep 17 00:00:00 2001 From: Mykola Bilochub Date: Sat, 22 Jul 2017 15:31:50 +0300 Subject: [PATCH 3/3] fixup! fixup! src: fix building on the old gcc versions --- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++----- 1 file changed, 37 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index d078d394..1dd86bc4 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,9 +1,41 @@ language: node_js node_js: - - 6 - - 7 - - 8 -dist: trusty -sudo: false + - "6.0" + - "6.1" + - "6.2" + - "6.3" + - "6.4" + - "6.5" + - "6.6" + - "6.7" + - "6.8" + - "6.9" + - "6.10" + - "6.11" + - "7.0" + - "7.1" + - "7.2" + - "7.3" + - "7.4" + - "7.5" + - "7.6" + - "7.7" + - "7.8" + - "7.9" + - "7.10" + - "8.0" + - "8.1" +env: + - CXX=g++-6 +addons: + apt: + sources: + - ubuntu-toolchain-r-test + packages: + - g++-6 + firefox: latest +before_script: + - export DISPLAY=:99.0 + - sh -e /etc/init.d/xvfb start script: - npm test