Forums
New posts
Search forums
Members
Current visitors
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
Forums
Archive
Archive
Java
Catching mulitple Exceptions in JDK 1.7
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
[QUOTE="Roedy Green, post: 4233049"] Here is a better example to illustrate my question: catch (IllegalArgumentException|IOException ex) What is the compile-time type of ex? What is the run-time type of ex if you got an IllegalArgumentException? What is the run-time type of ex if you got an IOException ? There may be more grown-up terms for "compile time type" and "run time type", but I think you know what I mean. Or is there a rule that catch (a | b ex ) requires a to be a subclass of b, which would neatly sidestep the problem, but then the feature would not do anything useful. [/QUOTE]
Verification
Post reply
Forums
Archive
Archive
Java
Catching mulitple Exceptions in JDK 1.7
Top