es5-ext
Advanced tools
Comparing version 0.10.5 to 0.10.6
@@ -9,6 +9,6 @@ 'use strict'; | ||
if (x === 0) return x; | ||
if (x === Infinity) return 1; | ||
if (x === -Infinity) return -1; | ||
if (x === Infinity) return Infinity; | ||
if (x === -Infinity) return -Infinity; | ||
if (x > 0) return floor(x); | ||
return -floor(-x); | ||
}; |
'use strict'; | ||
var assign = require('./assign') | ||
var forEach = Array.prototype.forEach, create = Object.create; | ||
, forEach = Array.prototype.forEach | ||
, create = Object.create, getPrototypeOf = Object.getPrototypeOf | ||
, process; | ||
process = function (src, obj) { | ||
var proto = getPrototypeOf(src); | ||
return assign(proto ? process(proto, obj) : obj, src); | ||
var process = function (src, obj) { | ||
var key; | ||
for (key in src) obj[key] = src[key]; | ||
}; | ||
@@ -14,0 +9,0 @@ |
{ | ||
"name": "es5-ext", | ||
"version": "0.10.5", | ||
"version": "0.10.6", | ||
"description": "ECMAScript 5 extensions and ES6 shims", | ||
@@ -29,7 +29,7 @@ "author": "Mariusz Nowak <medyk@medikoo.com> (http://www.medikoo.com/)", | ||
"dependencies": { | ||
"es6-iterator": "~0.1.2", | ||
"es6-symbol": "~0.1.1" | ||
"es6-iterator": "~0.1.3", | ||
"es6-symbol": "~2.0.1" | ||
}, | ||
"devDependencies": { | ||
"tad": "0.2", | ||
"tad": "~0.2.1", | ||
"xlint": "~0.2.2", | ||
@@ -36,0 +36,0 @@ "xlint-jslint-medikoo": "~0.1.2" |
@@ -8,4 +8,4 @@ 'use strict'; | ||
a(t(0), 0, "Zero"); | ||
a(t(Infinity), 1, "Infinity"); | ||
a(t(-Infinity), -1, "-Infinity"); | ||
a(t(Infinity), Infinity, "Infinity"); | ||
a(t(-Infinity), -Infinity, "-Infinity"); | ||
a(is(t(0.234), 0), true, "0"); | ||
@@ -12,0 +12,0 @@ a(is(t(-0.234), -0), true, "-0"); |
'use strict'; | ||
var create = Object.create; | ||
var create = Object.create, defineProperty = Object.defineProperty; | ||
@@ -12,2 +12,7 @@ module.exports = function (t, a) { | ||
x = { raz: 'one', dwa: 'two' }; | ||
defineProperty(x, 'get', { | ||
configurable: true, | ||
enumerable: true, | ||
get: function () { return this.dwa; } | ||
}); | ||
x = create(x); | ||
@@ -23,7 +28,7 @@ x.trzy = 'three'; | ||
a.deep(t(x), { raz: 'one', dwa: 'two!', trzy: 'three!', cztery: 'four', | ||
piec: 'five', szesc: 'six' }, "Deep object"); | ||
piec: 'five', szesc: 'six', get: 'two!' }, "Deep object"); | ||
a.deep(t({ marko: 'raz', raz: 'foo' }, x, { szesc: 'elo', siedem: 'bibg' }), | ||
{ marko: 'raz', raz: 'one', dwa: 'two!', trzy: 'three!', cztery: 'four', | ||
piec: 'five', szesc: 'elo', siedem: 'bibg' }, "Multiple options"); | ||
piec: 'five', szesc: 'elo', siedem: 'bibg', get: 'two!' }, "Multiple options"); | ||
}; |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
407663
6897
- Removedes6-symbol@0.1.1(transitive)
Updatedes6-iterator@~0.1.3
Updatedes6-symbol@~2.0.1