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 256928

Summary: NullPointerException at org.netbeans.modules.java.hints.suggestions.IfToSwitchSupport.evalConstant
Product: java Reporter: Vladimir Voskresensky <vv159170>
Component: HintsAssignee: Svata Dedic <sdedic>
Status: RESOLVED FIXED    
Severity: normal CC: gtzabari, tboudreau
Priority: P3    
Version: 8.2   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter: 221466
Attachments: stacktrace
stacktrace

Description Vladimir Voskresensky 2015-12-02 14:50:55 UTC
Build: NetBeans IDE Dev (Build 20151202-67e4a63165eb)
VM: Java HotSpot(TM) 64-Bit Server VM, 25.66-b17, Java(TM) SE Runtime Environment, 1.8.0_66-b17
OS: SunOS

User Comments:
vv159170: switch between files




Stacktrace: 
java.lang.NullPointerException
   at org.netbeans.modules.java.hints.suggestions.IfToSwitchSupport.evalConstant(IfToSwitchSupport.java:264)
   at org.netbeans.modules.java.hints.suggestions.IfToSwitchSupport.start(IfToSwitchSupport.java:354)
   at org.netbeans.modules.java.hints.suggestions.IfToSwitchSupport.process(IfToSwitchSupport.java:306)
   at org.netbeans.modules.java.hints.suggestions.ConvertIfToSwitch.convertIfToSwitch(ConvertIfToSwitch.java:142)
   at sun.reflect.GeneratedMethodAccessor206.invoke(GeneratedMethodAccessor206.java:0)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
Comment 1 Vladimir Voskresensky 2015-12-02 14:50:56 UTC
Created attachment 157615 [details]
stacktrace
Comment 2 _ tboudreau 2015-12-17 10:50:03 UTC
Created attachment 157821 [details]
stacktrace

Moved classes to another package
Comment 3 Svata Dedic 2016-01-28 15:27:33 UTC
Null check added in jet-main#7978321d6bee
Comment 4 Quality Engineering 2016-01-30 03:31:48 UTC
Integrated into 'main-silver', will be available in build *201601300002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/7978321d6bee
User: Svata Dedic <sdedic@netbeans.org>
Log: #256928: null check missing