Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(152)

Unified Diff: test/mjsunit/regress/regress-2419.js

Issue 233083003: Try to switch Array builtins into strict mode. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: test/mjsunit/regress/regress-2419.js
diff --git a/test/mjsunit/regress/regress-2419.js b/test/mjsunit/regress/regress-2419.js
index 4ffafbe6eb03a3ad29563131cc5a39b3304ca9ca..612e6dbfda31234d3f5a19d3c51dd3233163bda4 100644
--- a/test/mjsunit/regress/regress-2419.js
+++ b/test/mjsunit/regress/regress-2419.js
@@ -27,10 +27,10 @@
var a = [5, 4, 3, 2, 1, 0];
Object.freeze(a);
-a.sort();
+assertThrows(function() { a.sort(); });
assertArrayEquals([5, 4, 3, 2, 1, 0], a);
var b = {0: 5, 1: 4, 2: 3, 3: 2, 4: 1, 5: 0, length: 6};
Object.freeze(b);
-Array.prototype.sort.call(b);
+assertThrows(function() { Array.prototype.sort.call(b); });
assertPropertiesEqual({0: 5, 1: 4, 2: 3, 3: 2, 4: 1, 5: 0, length: 6}, b);
« test/mjsunit/regress/regress-1548.js ('K') | « test/mjsunit/regress/regress-1548.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698