checkstyle reports nullpointerexception on multi-catch blocks in static initializer blocks

54 Aufrufe
Direkt zur ersten ungelesenen Nachricht

André den Hartog

ungelesen,
19.02.2015, 04:09:4319.02.15
an check...@googlegroups.com
Hi,

I'm using Eclipse 4.3.2 with the Checkstyle 6.2 plugin. On the following class:

public class A {

    static {
        try {
            System.out.println("a");
        } catch (IllegalStateException | IllegalArgumentException e) {
            throw new RuntimeException(e);
        }
    }
}

Checkstyle (or the checkstyle plugin) reports:
Got an exception - java.lang.NullPointerException

Regards,
André

Roman Ivanov

ungelesen,
19.02.2015, 09:34:5219.02.15
an André den Hartog, check...@googlegroups.com

Can you share with us configuration that you use ?

--
You received this message because you are subscribed to the Google Groups "checkstyle" group.
To unsubscribe from this group and stop receiving emails from it, send an email to checkstyle+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

André den Hartog

ungelesen,
19.02.2015, 10:38:3019.02.15
an check...@googlegroups.com, hartog...@gmail.com
I've added 2 attachments to this post ...
checkstyle_suppressions.xml
checkstyle_eclipse_plugin.xml

Roman Ivanov

ungelesen,
19.02.2015, 11:07:3719.02.15
an André den Hartog, check...@googlegroups.com
thanks a lot - https://github.com/checkstyle/checkstyle/issues/654
we might have time to fix it very soon and release it at the end of month.

André den Hartog

ungelesen,
23.02.2015, 04:01:3223.02.15
an check...@googlegroups.com, hartog...@gmail.com
Ok, thanks!
Allen antworten
Antwort an Autor
Weiterleiten
0 neue Nachrichten