SETSWANA TRANSLATION: Skip to content

catchSets

SETSWANA TRANSLATION: Handles errors raised inside the preceding trySets block.

SETSWANA TRANSLATION: Use catchSets immediately after a trySets block. The parenthesised binding (e.g. (e)) receives the thrown value so your code can inspect or report it. If no error occurs in the trySets block, the catchSets block is skipped. This is a placeholder Setswana name — the canonical Setswana translation will be chosen later.

SETSWANA TRANSLATION: trySets { ... } catchSets (lebitso) { ... }
SETSWANA TRANSLATION: Log a caught error to the console
trySets {
  throwSets "phoso";
} catchSets (e) {
  kwala(e);
}

trySets, finallySets, throwSets