Bug 57076 - [reconciling] Outline view in Java Perspective does not always update correctly
Summary: [reconciling] Outline view in Java Perspective does not always update correctly
Status: RESOLVED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Text (show other bugs)
Version: 3.0   Edit
Hardware: Sun Solaris
: P2 major (vote)
Target Milestone: 3.0 M9   Edit
Assignee: JDT-Text-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-04-01 14:04 EST by Brian So CLA
Modified: 2004-05-21 06:29 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Brian So CLA 2004-04-01 14:04:31 EST
I found out that the Outline view in the Java Perspective does not always 
provide correct update information on 3.0M8 when editing a java file. This is 
how I did it:

1. Create a Java Project called 'AJava'.
2. Go to Java Perspective.
3. Create a Java Class called 'HelloWorld".
4. Paste in or type in the following program (exactly if you can including 
leading spaces although I do not think it makes any different):

public class HelloWorld
{
int myInt;
char myChar;
void methodB()
{
        myChar='A'; myInt=1234;
}
static void methodA()
{
        System.out.println("Salve Caesari!");
        // myInt=1234;
}
public static void main(String[] args)
{
        methodA();
        // myChar = 'B';
}
}

5. Save the program.
6. Expand the HelloWorld class tree in the Package Explorer and the Outline 
views. You should see all the methods and other info.
7. Remove the code "static void methodA()"
8. Save.
9. Add the code back with an error: "static void .ethodA()"
10. Save. Start to compare the errors listed on both views to see if there are 
any different.
11. Remove the error: "static void methodA()"
12. Save. You may see that on the Outline view there is an indication of error 
on 'main'.
13. Try again to add error back to the code: "static void .ethodA()".
14. Save. Compare the errors listed on both views to see if there are any 
different.
15. Remove the error: "static void methodA()"
16. Save. You should have on error on the Package Explorer view but you may see 
both the main and methodA show errors on the Outline view.

I have seen the problem on both Solaris 9 and HPUX11.11.
Comment 1 Brian So CLA 2004-04-06 09:55:47 EDT
Changing component from "Update" to "UI".
Comment 2 Dani Megert CLA 2004-04-13 03:46:36 EDT
Might be related to bug 55925
Comment 3 Brian So CLA 2004-04-13 09:53:01 EDT
-Sometimes (on HP11.11 only) I can reproduce it by plaing around wtiht the 
button " Go Into Top Level Type", "Sort", "Hide Fields", "Hide Static 
Members", "Hide Non-Public Members", and "Hide Local Types". Some of members 
may be renamed or disappeared.
- Editing or cut-and-paste a java file will definite cause outline view to 
misbehave.
- This may not be related:
On HPUX11.11 only with the Package Explorer view, sometimes when I removed a 
set of packages (say 5) containing java and other types of file, the Package 
Explorere view did not get updated properly. A remaining package get one of the 
deleted package name. Restart the workbench will solve the problem.
Comment 4 Dani Megert CLA 2004-05-21 06:29:50 EDT
We fixed several bugs in that area:
- tree viewer filter problem
- Java element delta problem

Can no longer reproduce using I200405210010. Please reopen if you still see this
using I200405210010 or newer.