Inspection Gadgets Exception in #3214

Error message: Exception happened in local inspection tool: Unnecessary 'return' statement
java.lang.NullPointerException

at com.siyeh.ig.verbose.UnnecessaryReturnInspection$UnnecessaryReturnVisitor.visitReturnStatement(UnnecessaryReturnInspection.java:67)

at com.intellij.psi.impl.source.tree.a.bn.accept(bn.java:14)

at com.intellij.psi.impl.source.tree.CompositePsiElement.acceptChildren(CompositePsiElement.java:20)

at com.intellij.psi.PsiRecursiveElementVisitor.visitElement(PsiRecursiveElementVisitor.java:11)

at com.intellij.psi.JavaElementVisitor.visitCodeBlock(JavaElementVisitor.java:66)

at com.intellij.psi.impl.source.tree.a.m.accept(m.java:44)

at com.intellij.psi.impl.source.tree.CompositePsiElement.acceptChildren(CompositePsiElement.java:20)

at com.intellij.psi.PsiRecursiveElementVisitor.visitElement(PsiRecursiveElementVisitor.java:11)

at com.intellij.psi.JavaElementVisitor.visitStatement(JavaElementVisitor.java:274)

at com.intellij.psi.JavaElementVisitor.visitBlockStatement(JavaElementVisitor.java:46)

at com.intellij.psi.impl.source.tree.a.i.accept(i.java:12)

at com.intellij.psi.impl.source.tree.CompositePsiElement.acceptChildren(CompositePsiElement.java:20)

at com.intellij.psi.PsiRecursiveElementVisitor.visitElement(PsiRecursiveElementVisitor.java:11)

at com.intellij.psi.JavaElementVisitor.visitStatement(JavaElementVisitor.java:274)

at com.intellij.psi.JavaElementVisitor.visitIfStatement(JavaElementVisitor.java:146)

at com.intellij.psi.impl.source.tree.a.y.accept(y.java)

at com.intellij.psi.impl.source.tree.CompositePsiElement.acceptChildren(CompositePsiElement.java:20)

at com.intellij.psi.PsiRecursiveElementVisitor.visitElement(PsiRecursiveElementVisitor.java:11)

at com.intellij.psi.JavaElementVisitor.visitCodeBlock(JavaElementVisitor.java:66)

at com.intellij.psi.impl.source.tree.a.m.accept(m.java:44)

at com.intellij.psi.impl.source.TreeWrapperPsiElement.acceptChildren(TreeWrapperPsiElement.java:35)

at com.intellij.psi.PsiRecursiveElementVisitor.visitElement(PsiRecursiveElementVisitor.java:11)

at com.intellij.psi.JavaElementVisitor.visitClassInitializer(JavaElementVisitor.java:58)

at com.intellij.psi.impl.source.m.accept(m.java:14)

at com.siyeh.ig.StatementInspection.checkClass(StatementInspection.java:19)

at com.intellij.codeInsight.daemon.impl.ba.doCollectInformation(ba.java:51)

at com.intellij.codeInsight.daemon.impl.TextEditorHighlightingPass.collectInformation(TextEditorHighlightingPass.java:0)

at com.intellij.codeInsight.daemon.impl.bf$1.run(bf$1.java:10)

at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:304)

at com.intellij.codeInsight.daemon.impl.bf.a(bf.java:24)

at com.intellij.codeInsight.daemon.impl.bf.access$100(bf.java:46)

at com.intellij.codeInsight.daemon.impl.bf$0.run(bf$0.java:3)

at com.intellij.openapi.progress.a.a.runProcess(a.java:60)

at com.intellij.codeInsight.daemon.impl.bf.run(bf.java:39)

2 comments
Comment actions Permalink

I've submitted a fix for this, should be in the next EAP. In the future, please submit InspectionGadgets issues via JIRA, as it makes it about ten times less likely that the issue will get missed or forgotten.

--Dave Griffith

0

Please sign in to leave a comment.