This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 246567

Summary: Null checks are not performed at all on static fields
Product: java Reporter: skiwi
Component: HintsAssignee: Svata Dedic <sdedic>
Status: NEW ---    
Severity: normal    
Priority: P2    
Version: 8.0.1   
Hardware: PC   
OS: Windows 8 x64   
Issue Type: ENHANCEMENT Exception Reporter:

Description skiwi 2014-08-20 07:38:22 UTC
Given the following code:

public class Bug2 {
    private final static String X = null;
    private final static String Y = X.trim();

    public static void main(String[] args) { }
}

No null checks are performed at all, I would expect a warning when calling X.trim().