Community
Participate
Working Groups
From bug 378724 comment 15: ---- Cast obscures nullness of a field: class NPEonCast { @Nullable private Object nullable; public void test() { if (nullable instanceof Number) { ((Number)nullable).intValue(); // A } if (nullable != null) { nullable.toString(); // B } nullable.toString(); // C } } Error missing for A (while correct for B and C) ---- While the result would be correct when syntactic analysis for fields is enabled (because the instanceof provides protection), without syntactic analysis we should see a warning, which we don't.
Trivial fix has been released for 4.3 M6 via commit 78e5ed0e34672db495ea2a17471c36349086fcd0
Verified for 4.3 M6 using Build id: I20130310-2000