Distinguish status from failure

Use check when an unsuccessful external status should become a catchable Flash error.

Snapshot
v0.2.0
Source path
components/flash/examples/checked-status.fsh
Tree
c41b976e0362
# A nonzero process status remains a value until check turns it into an error.
try {
    ^false | check
} catch error {
    let category = $error.category
    ^printf 'caught %s\n' $category
}

Return to Flash by Example →