зеркало из https://github.com/mozilla/gecko-dev.git
Fixed bug #7703, typeof<var> wasn't referencing activation frame vars
correctly.
This commit is contained in:
Родитель
f4713568a3
Коммит
4b314af77e
|
@ -592,7 +592,9 @@ public class Interpreter extends LabelTable {
|
|||
case TokenStream.TYPEOF : {
|
||||
String name = node.getString();
|
||||
int index = -1;
|
||||
if (itsInFunctionFlag)
|
||||
// use typeofname if an activation frame exists
|
||||
// since the vars all exist there instead of in jregs
|
||||
if (itsInFunctionFlag && !itsData.itsNeedsActivation)
|
||||
index = itsData.itsVariableTable.getOrdinal(name);
|
||||
if (index == -1) {
|
||||
iCodeTop = addByte((byte) TokenStream.TYPEOFNAME, iCodeTop);
|
||||
|
|
|
@ -592,7 +592,9 @@ public class Interpreter extends LabelTable {
|
|||
case TokenStream.TYPEOF : {
|
||||
String name = node.getString();
|
||||
int index = -1;
|
||||
if (itsInFunctionFlag)
|
||||
// use typeofname if an activation frame exists
|
||||
// since the vars all exist there instead of in jregs
|
||||
if (itsInFunctionFlag && !itsData.itsNeedsActivation)
|
||||
index = itsData.itsVariableTable.getOrdinal(name);
|
||||
if (index == -1) {
|
||||
iCodeTop = addByte((byte) TokenStream.TYPEOFNAME, iCodeTop);
|
||||
|
|
Загрузка…
Ссылка в новой задаче