# err! Assert that a value is `%Err` and extract its `:message`; if it is `%Ok`, return from the enclosing function with that Ok. Any other value passes through unchanged. Symmetric counterpart of `ok!`. ## Syntax
[err! $expr]
[$expr](err!)
Compiler-intercepted — both forms emit inline opcodes rather than a function call — so use it inside a function body. ## Examples
def msg-or-pass {|r|
    set m [err! $r]                  # on %Ok, msg-or-pass returns that Ok
    [str "failed: " $m]
}

[msg-or-pass [err "disk full"]]   # → "failed: disk full"
[msg-or-pass [ok 42]]             # → %Ok{:value 42}
## Returns The `:message` of an `%Err` (nil if the key is absent); on `%Ok`, the enclosing function returns the Ok immediately. Non-Result values pass through unchanged. ## See Also `ok!`, `err`, `ok`, `err?`, `unwrap`