Summary: | Bug in Unused Code > ... checked exception > Check overriding | ||
---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Nobody - feel free to take it <nobody> |
Component: | Core | Assignee: | Philipe Mulet <philippe_mulet> |
Status: | RESOLVED WONTFIX | QA Contact: | |
Severity: | critical | ||
Priority: | P3 | ||
Version: | 3.0 | ||
Target Milestone: | 3.0 M8 | ||
Hardware: | PC | ||
OS: | Windows XP | ||
Whiteboard: |
Description
Nobody - feel free to take it
2004-03-12 11:22:05 EST
Works for me. If the check option is enabled, then overriding/implementing methods are checked as well, if not, they are ignored. I think, I got the option's sense wrong. But now, another option is missing to me. I thought that the 'Check overriding' option would be what I am missing now. Please look at the following two classes ClassA and ClassB: public class ClassA { protected void foo() throws IOException {} } public class ClassB extends ClassA { protected void foo() throws IOException { throw new IOException(); } } foo() in ClassA needs to have the 'throws' clause because foo() in ClassB has a 'throws' clause and ClassB extends ClassA. Thus, the 'throws' clause in ClassA is NOT unnecessary and no warning or error should be shown. There could be an option for this - the one I said I was missing. |