Exceptions/Catch an exception thrown in a nested call: Difference between revisions

Content added Content deleted
 
Line 2,074: Line 2,074:
val .U1 = h{"msg": "U1"}
val .U1 = h{"msg": "U1"}


val .baz = fn(.i) throw if(.i==0: .U0; .U1)
val .baz = fn(.i) { throw if(.i==0: .U0; .U1) }
val .bar = fn(.i) .baz(.i)
val .bar = fn(.i) { .baz(.i) }


val .foo = impure fn() {
val .foo = impure fn() {