Fixed #1888 resolving types on nested function variables

This commit is contained in:
Jindra Petřík
2022-11-30 22:58:35 +01:00
parent c26030620f
commit 6f7a89b78f
26 changed files with 151 additions and 75 deletions
@@ -19,6 +19,7 @@ package com.jpexs.decompiler.graph.model;
import com.jpexs.decompiler.flash.abc.ABC;
import com.jpexs.decompiler.flash.abc.avm2.AVM2ConstantPool;
import com.jpexs.decompiler.flash.abc.avm2.parser.script.AbcIndexing;
import com.jpexs.decompiler.flash.abc.types.MethodBody;
import com.jpexs.decompiler.flash.action.model.ConstantPool;
import com.jpexs.decompiler.graph.DottedChain;
import java.util.HashMap;
@@ -39,6 +40,8 @@ public class LocalData {
public AVM2ConstantPool constantsAvm2;
public AbcIndexing abcIndex;
public List<MethodBody> callStack;
public HashMap<Integer, String> localRegNames;
@@ -54,7 +57,7 @@ public class LocalData {
return localData;
}
public static LocalData create(AbcIndexing abcIndex, ABC abc, HashMap<Integer, String> localRegNames, List<DottedChain> fullyQualifiedNames, Set<Integer> seenMethods) {
public static LocalData create(List<MethodBody> callStack, AbcIndexing abcIndex, ABC abc, HashMap<Integer, String> localRegNames, List<DottedChain> fullyQualifiedNames, Set<Integer> seenMethods) {
LocalData localData = new LocalData();
localData.abc = abc;
localData.constantsAvm2 = abc.constants;
@@ -62,6 +65,7 @@ public class LocalData {
localData.fullyQualifiedNames = fullyQualifiedNames;
localData.seenMethods = seenMethods;
localData.abcIndex = abcIndex;
localData.callStack = callStack;
return localData;
}
}