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 196895 - AssertionError: Unexpected kind: RESOURCE_VARIABLE
Summary: AssertionError: Unexpected kind: RESOURCE_VARIABLE
Status: VERIFIED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Compiler (show other bugs)
Version: 6.x
Hardware: All All
: P1 normal (vote)
Assignee: Dusan Balek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-20 19:18 UTC by Exceptions Reporter
Modified: 2011-03-24 08:44 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 177584


Attachments
stacktrace (6.53 KB, text/plain)
2011-03-20 19:18 UTC, Exceptions Reporter
Details
stacktrace (5.25 KB, text/plain)
2011-03-21 18:09 UTC, terje7601
Details
<no description> (7.95 KB, application/octet-stream)
2011-03-21 18:10 UTC, terje7601
Details
stacktrace (5.25 KB, text/plain)
2011-03-21 18:18 UTC, terje7601
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Exceptions Reporter 2011-03-20 19:18:17 UTC
This issue was reported manually by terje7601.
It already has 4 duplicates 


Build: NetBeans IDE Dev (Build 201103200400)
VM: Java HotSpot(TM) Client VM, 20.0-b02, Java(TM) SE Runtime Environment, 1.7.0-ea-b116
OS: Windows Vista

User Comments:
GUEST: Just editing a Java file. I get this error "a lot", btw.




Stacktrace: 
java.lang.AssertionError: Unexpected kind: RESOURCE_VARIABLE
   at com.sun.tools.javac.code.Kinds.kindName(Kinds.java:184)
   at com.sun.tools.javac.comp.Resolve$SymbolNotFoundError.getLocationDiag(Resolve.java:2027)
   at com.sun.tools.javac.comp.Resolve$SymbolNotFoundError.getDiagnostic(Resolve.java:2001)
   at com.sun.tools.javac.comp.Resolve.logResolveError(Resolve.java:1826)
   at com.sun.tools.javac.comp.Resolve.access(Resolve.java:1291)
   at com.sun.tools.javac.comp.Resolve.resolveQualifiedMethod(Resolve.java:1476)
Comment 1 Exceptions Reporter 2011-03-20 19:18:21 UTC
Created attachment 107137 [details]
stacktrace
Comment 2 Jan Lahoda 2011-03-20 20:11:00 UTC
Can be reproduced with source level == 1.7 on this file:
---------------------------------------------
package javaapplication1;

import java.io.FileInputStream;
import java.io.InputStream;

public class JavaApplication1 {

    public static void main(String[] args) {
        try (InputStream in = new FileInputStream("")) {
            in.u(); //note the unknown method
        }
    }
}
---------------------------------------------
Comment 3 terje7601 2011-03-21 18:09:58 UTC
Created attachment 107165 [details]
stacktrace

I had just started the IDE & opened 2 Java files
Comment 4 terje7601 2011-03-21 18:10:10 UTC
Created attachment 107166 [details]
<no description>
Comment 5 terje7601 2011-03-21 18:18:59 UTC
Created attachment 107167 [details]
stacktrace
Comment 6 terje7601 2011-03-21 19:12:38 UTC
I have 89 dumps coming from this error already...I 'm really surprised to be the first one to encounter this bug.
Comment 7 Dusan Balek 2011-03-22 08:26:23 UTC
Fixed in jet-main.

http://hg.netbeans.org/jet-main/rev/f3ebb5d8a476

changeset a5ca9c2dcc78 in main/nb-javac
details: http://hg.netbeans.org/main/nb-javac?cmd=changeset;node=a5ca9c2dcc78
Comment 8 Dusan Balek 2011-03-22 09:02:09 UTC
Could be very annoying. We should consider integrating the fix into 7.0.
Comment 9 Jan Lahoda 2011-03-22 09:06:14 UTC
The fix is OK, IMO.
Comment 10 Jaromir Uhrik 2011-03-22 15:29:03 UTC
Verified and no problem found in the following jet-main build:
Product Version: NetBeans IDE Dev (Build jet-main-3768-on-20110322)
Java: 1.7.0-ea; Java HotSpot(TM) Client VM 21.0-b03
System: Windows XP version 5.1 running on x86; Cp1250; en_US (nb)

I agree with the integration to 7.0.
Comment 11 Dusan Balek 2011-03-23 08:40:15 UTC
Integrated into release70.

http://hg.netbeans.org/releases/rev/c803356666ba
Comment 12 Quality Engineering 2011-03-23 09:59:25 UTC
Integrated into 'main-golden', will be available in build *201103230400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/f3ebb5d8a476
User: Dusan Balek <dbalek@netbeans.org>
Log: Issue #196895: AssertionError: Unexpected kind: RESOURCE_VARIABLE - fixed.
Comment 13 Jaromir Uhrik 2011-03-24 08:44:20 UTC
Verified in the following 7.0 build:
Product Version: NetBeans IDE 7.0 RC1 (Build 201103240000)
Java: 1.7.0-ea; Java HotSpot(TM) Client VM 21.0-b03
System: Windows XP version 5.1 running on x86; Cp1250; en_US (nb)