Bug 23829 - IType::resolveType incorrectly returns null
Summary: IType::resolveType incorrectly returns null
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: 2.1 M2   Edit
Assignee: Jerome Lanneluc CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-09-19 09:27 EDT by Adam Kiezun CLA
Modified: 2002-10-17 10:21 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 Adam Kiezun CLA 2002-09-19 09:27:11 EDT
0917
package p;

class B{}
class A extends B{
}

class Test{
	void f(){
		A a= new A();
		f(a);
	}
	void f(B b){
	}
}

try calling IType::resolveType("B") on p.Test
you get a nul, which is wrong - p.B should be returned

(all these types are declared in one file)
Comment 1 Philipe Mulet CLA 2002-09-23 03:50:16 EDT
Sounds like our secondary type limitation, even though the main type should be 
able to find it.
Comment 2 Jerome Lanneluc CLA 2002-10-03 08:52:06 EDT
When building the parse tree only the outermost type was considered.
Fixed by including all top level types of the cu.
Comment 3 David Audel CLA 2002-10-17 10:21:09 EDT
Verified.