зеркало из https://github.com/mozilla/pjs.git
Fixing a regression in Codegen.transform which effectively disabled direct call optimization: FunctionNode.FUNCTION_STATEMENT should be compared against fn.getFunctionType(), not fn.getType()
This commit is contained in:
Родитель
509a252295
Коммит
bb0cf4e75a
|
@ -95,7 +95,9 @@ public class Codegen extends Interpreter {
|
|||
for (int i = 0; i != functionCount; ++i) {
|
||||
OptFunctionNode fn;
|
||||
fn = (OptFunctionNode)tree.getFunctionNode(i);
|
||||
if (fn.getType() == FunctionNode.FUNCTION_STATEMENT) {
|
||||
if (fn.getFunctionType()
|
||||
== FunctionNode.FUNCTION_STATEMENT)
|
||||
{
|
||||
String name = fn.getFunctionName();
|
||||
if (name.length() != 0) {
|
||||
if (possibleDirectCalls == null) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче