[e-lang] Notes from latest Joe-E meeting
David Hopwood
david.hopwood at industrial-designers.co.uk
Mon Apr 30 21:01:32 EDT 2007
I wrote:
> A try/catch/finally can be written as:
>
> JoeE.tryFinallyThrowsChecked(new Thunk() { public void run() { try {
> ... X ...
> } catch (FooException e) {
> ... Y(e) ...
> }}}, new Thunk() { public void run() {
> ... Z ...
> }});
>
> which is arguably better than:
>
> JoeE.tryFinallyThrowsChecked(new Thunk() { public void run() {
I meant "JoeE.tryCatchFinallyThrowsChecked(..." here.
> ... X ...
> }}, new Catch() { public void handle(Exception e) {
> if (e instanceof FooException) {
> ... Y((FooException) e) ...
> } else { throw e; }
> }}, new Thunk() { public void run() {
> ... Z ...
> }});
--
David Hopwood <david.hopwood at industrial-designers.co.uk> (note new address)
More information about the e-lang
mailing list