quiet
Table of Contents
Function
quiet — quiet “missing” errors
Synopsis
quiet(val: any) -> any
Description
The quiet function returns its argument val
unless val
is
error("missing")
, in which case it returns error("quiet")
.
Various operators and functions treat quiet errors differently than
missing errors, in particular, dropping them instead of propagating them.
Quiet errors are ignored by operators cut
, summarize
, and yield
.
Examples
Yield processes a quiet error and thus no output:
yield quiet(this)
error("missing")
Loading...
Without quiet, yield produces the missing error:
yield this
error("missing")
Loading...
The cut
operator drops quiet errors but retains missing errors:
cut b:=x+1,c:=quiet(x+1),d:=quiet(a+1)
{a:1}
Loading...