biddyweb / checker-framework

Automatically exported from code.google.com/p/checker-framework
Other
0 stars 1 forks source link

Nullness Checker Static Initialization #353

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

The Nullness Checker fails to warn of a NullPointerException for this code:

class StaticDataflow {

    static String a;

    static {
        a.toString();
    }
}

What is the expected output? What do you see instead?
I expect a warning on the dereference of "a", but no error is given.

What version of the product are you using? On what operating system?
261dee828a0a

Original issue reported on code.google.com by mcart...@cs.washington.edu on 4 Sep 2014 at 9:35

GoogleCodeExporter commented 9 years ago
A test for this is in 
checker/tests/nullness/java8/lambda/Initialization.java:164

Original comment by mcart...@cs.washington.edu on 8 Sep 2014 at 11:03

GoogleCodeExporter commented 9 years ago

Original comment by mcart...@cs.washington.edu on 22 Jan 2015 at 12:58

GoogleCodeExporter commented 9 years ago
Added separate testcase: checker/tests/nullness/init/StaticInit.java

Original comment by mcart...@cs.washington.edu on 29 Jan 2015 at 8:14