mirror of
https://github.com/Eaglercraft-TeaVM-Fork/eagler-teavm.git
synced 2024-12-22 16:14:10 -08:00
Fix compiler crash when service enumerated in META-INF/service does not exist
This commit is contained in:
parent
07f946e710
commit
2f73272ed7
|
@ -62,10 +62,12 @@ public class ServiceLoaderSupport extends AbstractDependencyListener implements
|
||||||
writer.append(", ");
|
writer.append(", ");
|
||||||
}
|
}
|
||||||
String implName = implementations.get(i);
|
String implName = implementations.get(i);
|
||||||
|
if (context.getClassSource().getClassNames().contains(implName)) {
|
||||||
writer.append("[").appendClass(implName).append(", ").appendMethodBody(
|
writer.append("[").appendClass(implName).append(", ").appendMethodBody(
|
||||||
new MethodReference(implName, new MethodDescriptor("<init>", ValueType.VOID)))
|
new MethodReference(implName, new MethodDescriptor("<init>", ValueType.VOID)))
|
||||||
.append("]");
|
.append("]");
|
||||||
}
|
}
|
||||||
|
}
|
||||||
writer.append("];").softNewLine();
|
writer.append("];").softNewLine();
|
||||||
}
|
}
|
||||||
writer.outdent().append("}").softNewLine();
|
writer.outdent().append("}").softNewLine();
|
||||||
|
|
Loading…
Reference in New Issue
Block a user