mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-09-26 12:00:45 +00:00
generic parameters
This commit is contained in:
@@ -53,7 +53,7 @@ import java.util.Stack;
|
||||
*/
|
||||
public class ActionGraph extends Graph {
|
||||
|
||||
public ActionGraph(List code, HashMap<Integer, String> registerNames, HashMap<String, GraphTargetItem> variables, HashMap<String, GraphTargetItem> functions, int version) {
|
||||
public ActionGraph(List<Action> code, HashMap<Integer, String> registerNames, HashMap<String, GraphTargetItem> variables, HashMap<String, GraphTargetItem> functions, int version) {
|
||||
super(new ActionGraphSource(code, version, registerNames, variables, functions), new ArrayList<Integer>());
|
||||
//this.version = version;
|
||||
/*heads = makeGraph(code, new ArrayList<GraphPart>());
|
||||
@@ -63,10 +63,10 @@ public class ActionGraph extends Graph {
|
||||
}*/
|
||||
}
|
||||
|
||||
public static List<GraphTargetItem> translateViaGraph(HashMap<Integer, String> registerNames, HashMap<String, GraphTargetItem> variables, HashMap<String, GraphTargetItem> functions, List code, int version) {
|
||||
public static List<GraphTargetItem> translateViaGraph(HashMap<Integer, String> registerNames, HashMap<String, GraphTargetItem> variables, HashMap<String, GraphTargetItem> functions, List<Action> code, int version) {
|
||||
|
||||
ActionGraph g = new ActionGraph(code, registerNames, variables, functions, version);
|
||||
List localData = new ArrayList();
|
||||
List<Object> localData = new ArrayList<Object>();
|
||||
localData.add(registerNames);
|
||||
return g.translate(localData);
|
||||
}
|
||||
@@ -124,7 +124,7 @@ public class ActionGraph extends Graph {
|
||||
}
|
||||
|
||||
@Override
|
||||
protected List<GraphTargetItem> check(GraphSource code, List localData, List<GraphPart> allParts, Stack<GraphTargetItem> stack, GraphPart parent, GraphPart part, GraphPart stopPart, List<Loop> loops, List<GraphTargetItem> output, HashMap<Loop, List<GraphTargetItem>> forFinalCommands) {
|
||||
protected List<GraphTargetItem> check(GraphSource code, List<Object> localData, List<GraphPart> allParts, Stack<GraphTargetItem> stack, GraphPart parent, GraphPart part, GraphPart stopPart, List<Loop> loops, List<GraphTargetItem> output, HashMap<Loop, List<GraphTargetItem>> forFinalCommands) {
|
||||
if (!output.isEmpty()) {
|
||||
if (output.get(output.size() - 1) instanceof StoreRegisterTreeItem) {
|
||||
StoreRegisterTreeItem str = (StoreRegisterTreeItem) output.get(output.size() - 1);
|
||||
|
||||
Reference in New Issue
Block a user