| Summary: | [quick fix] Fix does offer cast to 'Object' | ||
|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Benno Baumgartner <benno.baumgartner> |
| Component: | UI | Assignee: | JDT-UI-Inbox <jdt-ui-inbox> |
| Status: | CLOSED WONTFIX | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | ||
| Version: | 3.3 | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Windows XP | ||
| Whiteboard: | stalebug | ||
Currently, the cast quick fix is only proposed if IFace really has a method doSmile. Cast quick fix is even available without the interface like the following:
package p;
public class A {
public static void main(String[] args) {
X x = new X();
x.doSomething();
}
}
class X {}
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. |
I20070717-1020 Given: package test; public class E01 { public interface IFace{} public static class MyFace implements IFace {} public void foo() { Object face= new MyFace(); face.doSmile(); } } 1. Ctrl-1 at error at doSmile 2. Select 'Add cast to face' Is: ((Object) face).doSmile(); Should: should be offer 2 qf: - Create doSmile in IFace - Create doSmile in Face