Bug 112561 - detect unused cycles of private members
Summary: detect unused cycles of private members
Status: NEW
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.1   Edit
Hardware: PC All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: JDT-Core-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-10-13 17:30 EDT by Adam Kiezun CLA
Modified: 2005-10-13 17:30 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 2005-10-13 17:30:56 EDT
3.1
not sure how common a problem that is but one could make an experiment before
implementing a check.

Detect cycles of unused private members. That is, currently the compiler flags
as unused any private member that is not read/called from *anywhere*.
But the member is just as dead if it is only called/read from only members that
are not reachable from any non-private member.

example of missed dead code (both methods are dead code - but the compiler does
not complain):

class A{
	private void foo(){
		bar();
	}

	private void bar() {
		foo();
	}
}