From cf06ee7f872608448872cd3e5d8871d30cad430a Mon Sep 17 00:00:00 2001 From: konsoletyper Date: Mon, 9 Feb 2015 23:48:22 +0400 Subject: [PATCH] Fix error building callgraph with JSFunctors --- .../main/java/org/teavm/jso/plugin/JSNativeGenerator.java | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/teavm-jso/src/main/java/org/teavm/jso/plugin/JSNativeGenerator.java b/teavm-jso/src/main/java/org/teavm/jso/plugin/JSNativeGenerator.java index 1bb899f8b..3f27a15d8 100644 --- a/teavm-jso/src/main/java/org/teavm/jso/plugin/JSNativeGenerator.java +++ b/teavm-jso/src/main/java/org/teavm/jso/plugin/JSNativeGenerator.java @@ -126,7 +126,7 @@ public class JSNativeGenerator implements Injector, DependencyPlugin { for (int i = 0; i < method.getReference().parameterCount(); ++i) { method.getVariable(i).addConsumer(new DependencyConsumer() { @Override public void consume(DependencyAgentType type) { - achieveFunctorMethods(agent, type.getName(), method, location); + achieveFunctorMethods(agent, type.getName(), method); } }); } @@ -137,15 +137,14 @@ public class JSNativeGenerator implements Injector, DependencyPlugin { } } - private void achieveFunctorMethods(DependencyAgent agent, String type, MethodDependency caller, - CallLocation location) { + private void achieveFunctorMethods(DependencyAgent agent, String type, MethodDependency caller) { if (caller.isMissing()) { return; } ClassReader cls = agent.getClassSource().get(type); if (cls != null) { for (MethodReader method : cls.getMethods()) { - agent.linkMethod(method.getReference(), location).use(); + agent.linkMethod(method.getReference(), null).use(); } } }