Bug 42280

Summary: Incorrectly identifies more generic catch block as hidden
Product: [Eclipse Project] JDT Reporter: Jon Christiansen <eclipse>
Component: CoreAssignee: JDT-Core-Inbox <jdt-core-inbox>
Status: RESOLVED INVALID QA Contact:
Severity: normal    
Priority: P3    
Version: 3.0   
Target Milestone: 3.0 M4   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
screenshot of circumstances none

Description Jon Christiansen CLA 2003-08-29 16:50:49 EDT
I have a try/catch block where there are three catches.

The first two catches are both subclasses of the Exception of the third catch, 
but there are additional subclasses of it as well, but Eclipse is stating 
that "Catch block is hidden by another one in the same try statement" and 
highlighting the third catch.
Comment 1 Jon Christiansen CLA 2003-08-29 16:52:50 EDT
Created attachment 5913 [details]
screenshot of circumstances

Screenshot showing wrong warning message AND Exception hierarchy in type
hierachy view
Comment 2 Philipe Mulet CLA 2003-08-30 04:23:52 EDT
What are the declared exceptions thrown by AgentListener.retrieveServerVersion
() ?

This warning is an optional diagnosis which can be turned off. But usually it 
is a good indication (meaning you can discard the offending catch block).
Comment 3 Jon Christiansen CLA 2003-08-30 15:03:30 EDT
Good catch, sorry about that, the call to retrieveServerVersion is declared to 
only return the two subclassed exceptions.