From 41d3b66867c587dae5e76617d5eb7b1665e11ff5 Mon Sep 17 00:00:00 2001 From: John-David Dalton Date: Thu, 3 Sep 2015 22:12:17 -0700 Subject: [PATCH] Move `NEGATIVE_INFINITY` and `POSITIVE_INFINITY` out of `runInContext`. --- lodash.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lodash.js b/lodash.js index 43c1695a3..0af18d89f 100644 --- a/lodash.js +++ b/lodash.js @@ -58,6 +58,10 @@ */ var MAX_SAFE_INTEGER = 9007199254740991; + /** Used as references for `-Infinity` and `Infinity`. */ + var NEGATIVE_INFINITY = 1 / -0, + POSITIVE_INFINITY = 1 / 0; + /** Used as the internal argument placeholder. */ var PLACEHOLDER = '__lodash_placeholder__'; @@ -1287,10 +1291,6 @@ // See https://es5.github.io/#x11.1.5 for more details. context = context ? _.defaults({}, context, _.pick(root, contextProps)) : root; - /** Used as references for `-Infinity` and `Infinity`. */ - var NEGATIVE_INFINITY = context.Number.NEGATIVE_INFINITY, - POSITIVE_INFINITY = context.Number.POSITIVE_INFINITY; - /** Native constructor references. */ var Date = context.Date, Error = context.Error,