Index: test/mjsunit/harmony/typedarrays.js |
diff --git a/test/mjsunit/harmony/typedarrays.js b/test/mjsunit/harmony/typedarrays.js |
index e20fbade9b07d99ecfabd558ca702dbfacd33d69..f26b0be56532ecaeb656e985ddd7410ac49a0079 100644 |
--- a/test/mjsunit/harmony/typedarrays.js |
+++ b/test/mjsunit/harmony/typedarrays.js |
@@ -310,6 +310,11 @@ function TestSubArray(constructor, item) { |
SubarrayTestCase(constructor, item, 10,90, 100, 90); |
SubarrayTestCase(constructor, item, 10,90, 100, -10); |
+ |
+ var method = constructor.prototype.subarray; |
+ method.call(new constructor(100), 0, 100); |
+ var o = {}; |
+ assertThrows(function() { method.call(o, 0, 100); }, TypeError); |
} |
TestSubArray(Uint8Array, 0xFF); |