From bd4e9f0a03ca7a651a79731633ddb1ba4d21cca1 Mon Sep 17 00:00:00 2001 From: Christian Holler Date: Wed, 13 Mar 2013 01:13:15 +0100 Subject: [PATCH] Bug 794025 - Add missing test for bug 794025. r=needed-tests --HG-- extra : rebase_source : 2e91ba614c130e1aa432824bfe1c7d29b18a209d --- js/src/jit-test/tests/basic/bug794025.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 js/src/jit-test/tests/basic/bug794025.js diff --git a/js/src/jit-test/tests/basic/bug794025.js b/js/src/jit-test/tests/basic/bug794025.js new file mode 100644 index 00000000000..c76eab73e5f --- /dev/null +++ b/js/src/jit-test/tests/basic/bug794025.js @@ -0,0 +1,15 @@ +// |jit-test| error:RangeError + +function getterFunction(v) { return "getter"; } +Object.defineProperty(Array.prototype, 1,{ + get: getterFunction, +}); +var N = (10000); +repeat_str("try { f(); } finally {\n", N), +repeat_str("}", ("" )); +function repeat_str(str, repeat_count) { + var arr = new Array(--repeat_count); + while (repeat_count != 0) + arr[--repeat_count] = str; + return str.concat.apply(str, arr); +}