From a12e27e16019dce7010a629ac443d355e9c4685b Mon Sep 17 00:00:00 2001
From: James Clark
@@ -9746,6 +9746,13 @@ Workers
default-worker-init := statement*
default-worker := statement*
named-worker-decl :=
- [annots] [transactional-qual] worker
worker-name return-type-descriptor statement-block
+ [annots] [transactional-qual] worker
worker-name return-type-descriptor statement-block [on-fail-clause]
worker-name := identifier
On fail clause
regular-compound-stmt will be handled by that regular-compound-statement.
+An on-fail-clause
attached to a named-worker-decl
is a
+shorthand for a named-worker-decl
with a statement block that is a
+do-stmt
with that on-fail-clause
: worker
+X { Y } on fail Z
is equivalent to
+worker X { do { Y } on fail Z }
.
+
If there is a typed-binding-pattern
, then it is matched to the
associated error value, binding the variables occurring within the
typed-binding-pattern
; the statement-block
is executed
@@ -11684,6 +11691,7 @@
retry
or transaction
statement may now have an on fail
clause.on fail
clause.