Bug 79690 - Find declaring node doesn't work for type variables
Summary: Find declaring node doesn't work for type variables
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.1   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.1 M4   Edit
Assignee: Olivier Thomann CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-11-29 13:21 EST by Dirk Baeumer CLA
Modified: 2004-12-15 12:54 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dirk Baeumer CLA 2004-11-29 13:21:41 EST
public class A_test1105 {
	public <E> void foo(E param) {
		/*[*/E local= param;
		foo(local);/*]*/
	}
}

- calling CompllationUnit#findDeclaringNode with the type binding representing
  E doesn't return the node <E> (e.g. the one in the method declaration)
Comment 1 Olivier Thomann CLA 2004-11-29 13:34:16 EST
It isn't specified to be working for type variables.
Comment 2 Olivier Thomann CLA 2004-11-29 21:15:49 EST
Jim,

We might want to add type variables in the specifications.
Comment 3 Jim des Rivieres CLA 2004-11-30 09:36:00 EST
I've revised spec for both CompllationUnit.findDeclaringNode(*) methods to 
cover IBindings for type variables:

	 * <li>type variable - a <code>TypeParameter</code></li>
Comment 4 Jim des Rivieres CLA 2004-11-30 13:55:54 EST
Olivier,  Re-assigning to you for backing implementation.
Comment 5 Olivier Thomann CLA 2004-11-30 15:57:38 EST
Fixed and released in HEAD.
Regression test added in ASTConverter15Test.test0088.
Comment 6 Jerome Lanneluc CLA 2004-12-15 12:54:10 EST
Verified (in I20041214-2000) that the test ensures that findDeclaringNode
returns a type parameter for the type of the local.