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 - Null checks are not performed at all on static fields
Summary: Null checks are not performed at all on static fields
Status: NEW
Alias: None
Product: java
Classification: Unclassified
Component: Hints (show other bugs)
Version: 8.0.1
Hardware: PC Windows 8 x64
: P2 normal (vote)
Assignee: Svata Dedic
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-08-20 07:38 UTC by skiwi
Modified: 2014-08-20 08:10 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
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().