Anonymous user
Exceptions/Catch an exception thrown in a nested call: Difference between revisions
Exceptions/Catch an exception thrown in a nested call (view source)
Revision as of 09:00, 5 September 2018
, 5 years ago→{{header|Elena}}
(Remove Omit tag for Swift.) |
|||
Line 886:
</pre>
=={{header|Elena}}==
ELENA 3.
<lang elena>import extensions.
class U0 :: Exception.
class U1 :: Exception.
singleton Exceptions
{
static int i.
bar
<= baz.
baz
[
Line 910:
]
]
foo
[
Line 916:
while (i < 2)
[
try(
{
on(U0 e)
Line 923:
]
}.
i += 1.
]
]
}
[
Exceptions foo.
]
{{out}}
<pre>
|