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 253608 - NullPointerException at com.sun.tools.javac.comp.Analyzer$LambdaAnalyzer.match
Summary: NullPointerException at com.sun.tools.javac.comp.Analyzer$LambdaAnalyzer.match
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Compiler (show other bugs)
Version: 8.1
Hardware: All All
: P2 normal with 1 vote (vote)
Assignee: Dusan Balek
URL:
Keywords:
: 253975 (view as bug list)
Depends on:
Blocks:
 
Reported: 2015-07-21 08:58 UTC by Alexandr Scherbatiy
Modified: 2016-08-27 02:19 UTC (History)
9 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 218344


Attachments
stacktrace (4.54 KB, text/plain)
2015-07-21 08:58 UTC, Alexandr Scherbatiy
Details
stacktrace (4.07 KB, text/plain)
2015-12-10 09:43 UTC, Jiri Prox
Details
stacktrace (7.55 KB, text/plain)
2015-12-15 16:11 UTC, abien
Details
stacktrace (4.53 KB, text/plain)
2016-01-06 13:32 UTC, Jiri Prox
Details
stacktrace (5.29 KB, text/plain)
2016-03-22 09:59 UTC, Alexander Simon
Details
stacktrace (7.52 KB, text/plain)
2016-06-24 17:57 UTC, _ tboudreau
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alexandr Scherbatiy 2015-07-21 08:58:55 UTC
Build: NetBeans Dev JDK9 branch (Build 201506180405)
VM: Java HotSpot(TM) Client VM, 1.9.0-ea-b73, Java(TM) SE Runtime Environment, 1.9.0-ea-b73
OS: Windows 7

User Comments:
GUEST: the error occured  during normal usage of the editor, scrolling over the hint to replace anonymous class with lambda expression. I can't do that as the source level is set to 1.6 - i also think that the hint should be adjusted to current source level setting

GUEST: 1)I have created a list
2)In ArrayList<String>();
3)After selecting the String I got the popup showing the NullPointerException

sunflower: edit code




Stacktrace: 
java.lang.NullPointerException
   at com.sun.tools.javac.comp.Analyzer$LambdaAnalyzer.match(Analyzer.java:261)
   at com.sun.tools.javac.comp.Analyzer$LambdaAnalyzer.match(Analyzer.java:251)
   at com.sun.tools.javac.comp.Analyzer$StatementScanner.scan(Analyzer.java:422)
   at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:57)
   at com.sun.tools.javac.tree.TreeScanner.visitApply(TreeScanner.java:203)
   at com.sun.tools.javac.tree.JCTree$JCMethodInvocation.accept(JCTree.java:1606)
Comment 1 Alexandr Scherbatiy 2015-07-21 08:58:57 UTC
Created attachment 154758 [details]
stacktrace
Comment 2 Dusan Balek 2015-08-06 10:23:26 UTC
*** Bug 253975 has been marked as a duplicate of this bug. ***
Comment 3 Exceptions Reporter 2015-11-02 20:51:59 UTC
This bug already has 5 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=218344
Comment 4 Jiri Prox 2015-12-10 09:43:16 UTC
Created attachment 157743 [details]
stacktrace

NPE when editing source
Comment 5 abien 2015-12-15 16:11:00 UTC
Created attachment 157798 [details]
stacktrace

Happened during copy and paste
Comment 6 Jiri Prox 2016-01-06 13:32:03 UTC
Created attachment 158028 [details]
stacktrace

NPE when trying reproduce issue 257431
Comment 7 Exceptions Reporter 2016-01-06 13:32:07 UTC
This bug already has 10 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=218344
Comment 8 Alexander Simon 2016-03-22 09:59:29 UTC
Created attachment 158961 [details]
stacktrace

go to usage
Comment 9 _ tboudreau 2016-06-24 17:57:27 UTC
Created attachment 160159 [details]
stacktrace

Opened a refactored file that references non-existent classes
Comment 10 Exceptions Reporter 2016-08-23 08:24:34 UTC
This bug already has 20 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=218344
Comment 12 Quality Engineering 2016-08-27 02:19:50 UTC
Integrated into 'main-silver', will be available in build *201608270002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/0a1f5b99e4d0
User: Dusan Balek <dbalek@netbeans.org>
Log: Issues #253608, #267646, and #267678 fixed.