 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
| • |
Try
blocks can be nested, either statically at compile time
|
|
|
or
dynamically based on the flow of control.
|
|
| • |
When
we throw an exception, the catch blocks associated
|
|
|
with
the try block containing the throw are searched for a
|
|
|
type
matching the exception.
|
|
| • |
If no
match is found, the catch blocks associated with the
|
|
|
statically
or dynamically surrounding try block (i.e., a try
|
|
|
block
entered, but not exited) are searched.
|
|
| • |
This
process continues until either a matching catch block
|
|
|
is
found or there are no more try blocks, in which case the
|
|
function
terminate is called.
|
|