Status: New
Owner: ----
Labels: Type-Defect Priority-Medium
New issue 26 by
benv...@google.com: ArrayBuffer.prototype.slice is now
shipping in browsers, slice.js throws
http://code.google.com/p/google-js-test/issues/detail?id=26
When running a generated HTML page in Chromium I'm hitting an exception in
gjstest/internal/slice.js:
if ('slice' in ArrayBuffer.prototype) {
throw new Error("ArrayBuffer.prototype.slice is already defined.");
}
This is because very recent browsers have unprefixed
ArrayBuffer.prototype.slice, meaning that when running in a browser this
dies. The polyfill in this file should invert its test to only add the
slice method if it doesn't exist, instead of dying when it does.