Bug 86644

Summary: infer type args: incorrect with method type params used as type args
Product: [Eclipse Project] JDT Reporter: Adam Kiezun <akiezun>
Component: UIAssignee: Markus Keller <markus.kell.r>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 3.1   
Target Milestone: 3.1 M7   
Hardware: All   
OS: All   
Whiteboard:
Bug Depends on: 87050    
Bug Blocks:    

Description Adam Kiezun CLA 2005-02-25 11:04:54 EST
3.1M5a
public class Cell{
  public <T> T f1(T l){
	  Vector v= new Vector();
	  v.add(l);
	  return (T)v.get(0);
  }
}

it infers:
public class Cell{
  public <T> T f1(T l){
	  Vector<Cell> v= new Vector<Cell>();
	  v.add(l);
	  return v.get(0);
  }
}

(fyi: i'm working on 'our' side of this problem)
Comment 1 Adam Kiezun CLA 2005-02-25 15:59:22 EST
sorry - reassignment happened by mistake
Comment 2 Markus Keller CLA 2005-03-03 03:17:56 EST
This is due to bug 87050. The refactoring correctly calculates <T> as type
argument for Vector, but JDT/Core doesn't correctly resolve the binding from the
key.
Comment 3 Markus Keller CLA 2005-05-08 09:09:51 EDT
Was indeed bug 87050. Fixed in HEAD.