Fix new ArrayBuffer(length) for variaous input (#1959)
Currently new ArrayBuffer(length) does not conform to ES2017. Major JS implementations follow ES2017 for ArrayBuffer(length). For example, new ArrayBuffer(length) should not throw RangeError for length = NaN, undefined, negative number, floating point, and so on. JerryScript-DCO-1.0-Signed-off-by: Sanggyu Lee sg5.lee@samsung.com
This commit is contained in:
committed by
Zidong Jiang
parent
af16a3ae1a
commit
c1cff3f961
@@ -15,3 +15,4 @@
|
||||
|
||||
var a = new ArrayBuffer(5);
|
||||
assert(typeof a === 'object');
|
||||
assert(a.byteLength === 5);
|
||||
|
||||
Reference in New Issue
Block a user