Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 355534 - [quick fix] Quick fix suggest casting to only one type when multiple overloaded functions are present
Summary: [quick fix] Quick fix suggest casting to only one type when multiple overload...
Status: CLOSED DUPLICATE of bug 361601
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.7   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: JDT-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-23 12:18 EDT by Ankur Sharma CLA
Modified: 2011-10-24 19:56 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 Ankur Sharma CLA 2011-08-23 12:18:21 EDT
Snippet:

public class Class {
	public void overloadedFunction(Boolean b) {
		
	}
	
	public void overloadedFunction(String str) {
		
	}
	
	public void function(){
		Object i;
		overloadedFunction(i);	//Check the quick fix here
	}
}


The quick fix at overloadedFunction(i) suggests to cast 'i' to Boolean only. It should also provide a quick fix to cast it to String.
Comment 1 Raksha Vasisht CLA 2011-10-24 15:19:27 EDT
(In reply to comment #0)

> 
> The quick fix at overloadedFunction(i) suggests to cast 'i' to Boolean only. It
> should also provide a quick fix to cast it to String.

Yep. It only shows the first one.
Comment 2 Deepak Azad CLA 2011-10-24 19:56:33 EDT

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