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 50907 - Mixed up elements
Summary: Mixed up elements
Status: CLOSED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Unsupported (show other bugs)
Version: 4.x
Hardware: PC Windows XP
: P2 blocker (vote)
Assignee: Martin Matula
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-10-27 14:23 UTC by Jan Pokorsky
Modified: 2007-09-26 09:14 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
stacktraces (8.96 KB, text/plain)
2004-10-27 14:25 UTC, Jan Pokorsky
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Pokorsky 2004-10-27 14:23:37 UTC
Have a modified source file

public class NewClass {
    public NewClass() {
    }
    public static class B
    public static class A {
        private int a = 0;
    }
}

If you stop typing after B inner class you get NPE
from JavaEditor that tries to get an element on
the current offset. JavaEditor gets the resource,
clasifiers and their features. Then it askes for
position of each feature
(JavaMetamodel.getElementPosition). It looks like
one of features is NewClass.B.A which is wrong. I
have added some debug info to JavaEditor to
identify the problem. See the attached stacktraces
Comment 1 Jan Pokorsky 2004-10-27 14:25:59 UTC
Created attachment 18563 [details]
stacktraces
Comment 2 Martin Matula 2004-10-28 11:31:05 UTC
Fixed.

Checking in src/org/netbeans/modules/javacore/parser/MDRParser.java;
/cvs/java/javacore/src/org/netbeans/modules/javacore/parser/MDRParser.java,v
 <--  MDRParser.java
new revision: 1.61; previous revision: 1.60
done
Comment 3 Jan Pokorsky 2004-10-28 11:33:14 UTC
verified
Comment 4 Quality Engineering 2007-09-20 09:50:13 UTC
Reorganization of java component