Bug 559438 - Decompiler bug with JSOP_CONCATN. r=shaver.

This commit is contained in:
Jason Orendorff 2010-04-14 17:26:44 -05:00
Родитель 897e13f450
Коммит 0089afc587
3 изменённых файлов: 12 добавлений и 1 удалений

Просмотреть файл

@ -3551,7 +3551,7 @@ Decompile(SprintStack *ss, jsbytecode *pc, intN nb, JSOp nextop)
ok = JS_FALSE;
for (i = argc - 1; i >= 0; i--) {
argv[i] = JS_strdup(cx, POP_STR());
argv[i] = JS_strdup(cx, POP_STR_PREC(cs->prec + 1));
if (!argv[i])
goto out;
}

Просмотреть файл

@ -10,3 +10,4 @@ script regress-541455.js
script regress-546615.js
script regress-555246-0.js
fails script regress-555246-1.js
script regress-559438.js

Просмотреть файл

@ -0,0 +1,10 @@
/*
* Any copyright is dedicated to the Public Domain.
* http://creativecommons.org/licenses/publicdomain/
* Contributor: Jason Orendorff
*/
function f(x) { return 1 + "" + (x + 1); }
reportCompare("12", f(1), "");
var g = eval(String(f));
reportCompare("12", f(1), "");