Bug 73608 - [1.5] spurious error when compiling generic method
Summary: [1.5] spurious error when compiling generic method
Status: RESOLVED DUPLICATE of bug 72644
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.0   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: JDT-Core-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-09-09 16:08 EDT by Michael McDougall CLA
Modified: 2004-09-09 16:47 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael McDougall CLA 2004-09-09 16:08:28 EDT
I am trying to compile the following method

public static <K,V> Set<K> inverseImage(Map<K,V> inMap, V inVal) {
		
		Set<Map<K,V>.Entry<K,V>> entrySet = 
			inMap.entrySet();
		Set<K> resultSet = new TreeSet<K>();
		//irrelevant stuff omitted
		return resultSet;
	}

It looks ok to me. The J2SE 5.0 RC compile will accept it without complaining.
But Eclipse 3.0 + Cheetah 0.6 gives the following error:

Type mismatch: cannot convert from Set<Map<K,V>.Entry<K,V>> to
Set<Map<K,V>.Entry<K,V>>	MapUtil.java	polaris/src/edu/upenn/polaris/support	line 20	

(the line 20 is the line where 'entrySet' is declared).
Comment 1 Kent Johnson CLA 2004-09-09 16:47:36 EDT

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