Bug 37897

Summary: Open type on console stack trace fails if top-level but not filename type
Product: [Eclipse Project] JDT Reporter: Wes Isberg <wes>
Component: CoreAssignee: JDT-Core-Inbox <jdt-core-inbox>
Status: RESOLVED DUPLICATE QA Contact:
Severity: normal    
Priority: P3    
Version: 2.1   
Target Milestone: 3.0 M1   
Hardware: PC   
OS: Windows NT   
Whiteboard:

Description Wes Isberg CLA 2003-05-20 20:16:50 EDT
When an exception is shown in the console, navigation fails after clicking on a
line for a type at the top level of a file but not named by the filename.

1) create a new Java project

2) create a new package "app"

3) create the following file in the package:

---- app/Main.java
package app;

public class Main{
    public static void main(String[] args) {
        C.go();
    }
}
class C {
    static void go() {
        throw new RuntimeException("error"); 
    }
}
-----

4) Compile and run app.Main
   (a stack trace appears in the console)

5) click the top line of the trace
BUG: alert "source not found for app.C"

- expected to navigate to line in app.C
- open-type (ctrl-shift-T) works to find C
- (?? using open type rather than using{file}:{line}?)

Sorry if duplicate; I searched variants of [open type console trace] in bug
summary, found none wrt top-level but not filename types.
Comment 1 Philipe Mulet CLA 2003-05-21 05:25:06 EDT
This is another symptom of secondary types causing us grief when looked for. We 
are planning to improve this for 3.0, but our current support would be way to 
expensive to enable (since secondary types are not frequent, and generally 
considered as bad style).
Comment 2 Philipe Mulet CLA 2003-05-21 05:26:16 EDT

*** This bug has been marked as a duplicate of 36032 ***