Bug 301736 - [quick fix] offer downcasting interfaces for a bounded parameter argument
Summary: [quick fix] offer downcasting interfaces for a bounded parameter argument
Status: ASSIGNED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.6   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: JDT-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-02-03 13:28 EST by Remy Suen CLA
Modified: 2010-02-04 05:49 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Remy Suen CLA 2010-02-03 13:28:33 EST
Build id: I20100202-0800

I would like the quick fix to offer casting 'test' to 'Test' so the copy becomes 'copy((Test) test);'.

public class Test {
	
  static interface TestInterface {}
	
  static <T extends Test> T copy(T t) {
    return null;
  }
	
  static void v(TestInterface test) {
    copy(test);
  }

}