| Summary: | Enum defined within class incorrectly imported | ||
|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Lawrence Weetman <contact> |
| Component: | UI | Assignee: | JDT-UI-Inbox <jdt-ui-inbox> |
| Status: | CLOSED WONTFIX | QA Contact: | |
| Severity: | minor | ||
| Priority: | P3 | CC: | contact, noopur_gupta |
| Version: | 3.8.1 | ||
| Target Milestone: | --- | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | stalebug | ||
|
Description
Lawrence Weetman
Slight correction to this: it turns out that organizing imports DOES remove the enum import as expected. The bug which _does_ exist is as follows: 1) Define enum MyEnum within class MyClass. 2) Create another class, such as MyTest. 3) Use a non-existent method with from MyClass in MyTest, such as MyClass.myMethod(MyEnum enum). 4) Use the problem-fixing menu (Ctrl+1) to generate myMethod in MyClass. At this point, an import for MyEnum is added within the defining class, MyClass. However, contrary to what I said earlier, organising imports (Ctrl + Shft + O) does remove this. It also seems to be the case that if you later extract MyEnum from MyClass using the refactoring tools, the import statements within MyClass are not updated correctly. Reproducible in Eclipse 3.8.1 also. This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug. If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie. |