NPE while calling getSuperclassesForType in LangServ
PseudoKnight opened this issue ยท 0 comments
I've only experienced this three times and only in the LangServ when using the VSCode extension. I'm not able to reproduce it reliably, but it seems to occur on startup.
So far the NPE has occurred with the type being ms.lang.Iterable or ms.lang.mixed.
SEVERE: [ERROR][langserv] java.lang.RuntimeException: NPE while calling getSuperclassesForType for type ms.lang.Iterable
at com.laytonsmith.core.constructs.CClassType.getSuperclassesForType(CClassType.java:441)
at com.laytonsmith.core.constructs.InstanceofUtil.getAllCastableClassesWithBlacklist(InstanceofUtil.java:44)
at com.laytonsmith.core.constructs.InstanceofUtil.getAllCastableClassesWithBlacklist(InstanceofUtil.java:48)
at com.laytonsmith.core.constructs.InstanceofUtil.getAllCastableClasses(InstanceofUtil.java:26)
at com.laytonsmith.core.constructs.InstanceofUtil.isInstanceof(InstanceofUtil.java:75)
at com.laytonsmith.core.constructs.InstanceofUtil.isInstanceof(InstanceofUtil.java:105)
at com.laytonsmith.core.functions.StringHandling$sconcat.optimizeDynamic(StringHandling.java:259)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2316)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.compile(MethodScriptCompiler.java:1769)
at com.laytonsmith.tools.langserv.LangServ.lambda$doCompilation$9(LangServ.java:696)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.NullPointerException
at com.laytonsmith.core.constructs.CClassType.lambda$getSuperclassesForType$3(CClassType.java:436)
at java.util.stream.ReferencePipeline$7$1.accept(Unknown Source)
at java.util.Spliterators$ArraySpliterator.forEachRemaining(Unknown Source)
at java.util.stream.AbstractPipeline.copyInto(Unknown Source)
at java.util.stream.AbstractPipeline.wrapAndCopyInto(Unknown Source)
at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(Unknown Source)
at java.util.stream.AbstractPipeline.evaluate(Unknown Source)
at java.util.stream.ReferencePipeline.collect(Unknown Source)
at com.laytonsmith.core.constructs.CClassType.getSuperclassesForType(CClassType.java:437)
... 21 more
Caused by: java.lang.NullPointerException
at com.laytonsmith.core.constructs.CClassType.lambda$getSuperclassesForType$3(CClassType.java:436)
at java.util.stream.ReferencePipeline$7$1.accept(Unknown Source)
at java.util.Spliterators$ArraySpliterator.forEachRemaining(Unknown Source)
at java.util.stream.AbstractPipeline.copyInto(Unknown Source)
at java.util.stream.AbstractPipeline.wrapAndCopyInto(Unknown Source)
at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(Unknown Source)
at java.util.stream.AbstractPipeline.evaluate(Unknown Source)
at java.util.stream.ReferencePipeline.collect(Unknown Source)
at com.laytonsmith.core.constructs.CClassType.getSuperclassesForType(CClassType.java:437)
at com.laytonsmith.core.constructs.InstanceofUtil.getAllCastableClassesWithBlacklist(InstanceofUtil.java:44)
at com.laytonsmith.core.constructs.InstanceofUtil.getAllCastableClassesWithBlacklist(InstanceofUtil.java:48)
at com.laytonsmith.core.constructs.InstanceofUtil.getAllCastableClasses(InstanceofUtil.java:26)
at com.laytonsmith.core.constructs.InstanceofUtil.isInstanceof(InstanceofUtil.java:75)
at com.laytonsmith.core.constructs.InstanceofUtil.isInstanceof(InstanceofUtil.java:105)
at com.laytonsmith.core.functions.StringHandling$sconcat.optimizeDynamic(StringHandling.java:259)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2316)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.optimize(MethodScriptCompiler.java:2212)
at com.laytonsmith.core.MethodScriptCompiler.compile(MethodScriptCompiler.java:1769)
at com.laytonsmith.tools.langserv.LangServ.lambda$doCompilation$9(LangServ.java:696)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)