Bug 31765

Summary: private recursive methods not marked as unused
Product: [Eclipse Project] JDT Reporter: Adam Kiezun <akiezun>
Component: CoreAssignee: Philipe Mulet <philippe_mulet>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: Olivier_Thomann
Version: 2.1   
Target Milestone: 2.1 RC2   
Hardware: PC   
OS: Windows 2000   
Whiteboard:

Description Adam Kiezun CLA 2003-02-13 07:33:28 EST
20030211
method foo should be marked as unused

class Test{
	private int foo(int i){
		if (i<=0) return 0;
		return 7 + foo(i-1);
	}
}
Comment 1 Philipe Mulet CLA 2003-02-13 08:12:16 EST
Post 2.1. Indirect recursions would be way more complex to address.
Comment 2 Philipe Mulet CLA 2003-02-19 12:21:24 EST
*** Bug 32250 has been marked as a duplicate of this bug. ***
Comment 3 Philipe Mulet CLA 2003-03-01 05:10:27 EST
May go for the direct case only.
Comment 4 Philipe Mulet CLA 2003-03-03 08:59:17 EST
Fixed in latest.
Comment 5 Philipe Mulet CLA 2003-03-03 09:08:29 EST
Made similar change to ignore references to a private type from within itself.
Comment 6 Philipe Mulet CLA 2003-03-03 09:23:14 EST
Also do not consider usage of private field from within inside itself.
Comment 7 Philipe Mulet CLA 2003-03-05 06:34:12 EST
Forgot to assign
Comment 8 Philipe Mulet CLA 2003-03-05 06:34:43 EST
Fixed
Comment 9 David Audel CLA 2003-03-10 11:32:45 EST
Verified.