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

Unified Diff: test/mjsunit/big-array-literal.js

Issue 25025002: Use a walking visitor to traverse JSObject structure. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Missed a spot! Created 7 years, 3 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
« no previous file with comments | « src/objects.cc ('k') | test/mjsunit/big-object-literal.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/big-array-literal.js
diff --git a/test/mjsunit/big-array-literal.js b/test/mjsunit/big-array-literal.js
index 9f0617989caf3a934f48ccde68e5d35c117ea252..13f91f855e1824531b2e10f2427b869e6b848252 100644
--- a/test/mjsunit/big-array-literal.js
+++ b/test/mjsunit/big-array-literal.js
@@ -92,16 +92,25 @@ for (var i = 0; i < sizes.length; i++) {
testLiteral(sizes[i], true);
}
+
+function checkExpectedException(e) {
+ assertInstanceof(e, RangeError);
+ assertTrue(e.message.indexOf("Maximum call stack size exceeded") >= 0);
+}
+
+
function testLiteralAndCatch(size) {
var big_enough = false;
try {
testLiteral(size, false);
} catch (e) {
+ checkExpectedException(e);
big_enough = true;
}
try {
testLiteral(size, true);
} catch (e) {
+ checkExpectedException(e);
big_enough = true;
}
return big_enough;
« no previous file with comments | « src/objects.cc ('k') | test/mjsunit/big-object-literal.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698