$ check main
= 1
E007 main:1 Unresolved lib.nothere
E007 main:2 Unresolved lib.Nothere
E007 main:3 Unresolved lib.NOTHERE
E007 main:4 Unresolved lib.exit
$ build typed
= 1
E007 typed:0 Unresolved lib.Nope
E007 typed:0 Unresolved nolib.Item
$ check alone
= 1
E007 alone:1 Unresolved lib
$ check word
= 1
E005 word:1 UnknownType "buffer" is a definition here, not a type
E015 word:1 Escape byte is a function, not a value
E009 word:1 Arity decode has too many arguments
$ check capped
= 1
E005 capped:0 UnknownType cap takes Memory, Channel, Any, Display, Input or Clipboard
$ check lib.kind
= 0
stacks 0
fn lib.kind none
$ full lib.kind
= 0
-- After cap, Memory is the capability kind, not lib.Memory beside it.
fn kind m cap Memory, n @lib.Memory -> int = n.a
$ full lib.chan
= 0
-- The same where a type is written as an expression.
fn chan n @lib.Memory -> int = {
  let tx, rx = channel cap Memory
  drop tx
  drop rx
  n.a
}
$ check lib.hidden
= 1
E005 lib.hidden:1 UnknownType "buffer" is a definition here, not a type
E015 lib.hidden:1 Escape byte is a function, not a value
E009 lib.hidden:1 Arity decode has too many arguments
$ check lib.local
= 0
stacks 0
fn lib.local none
$ full lib.local
= 0
-- A local named cap changes nothing where a type is read: cap Memory is
-- still the capability type, and the local is still the local after it.
fn local n @lib.Memory -> int = {
  let cap = 1
  let tx, rx = channel cap Memory
  drop tx
  drop rx
  n.a + cap
}
$ check lib.off
= 0
stacks 0
fn lib.off none
$ full lib.off
= 0
-- Past the type the words are names again: cap is the parameter and OFF
-- the constant.
fn off cap view byte -> int = load int cap @lib.OFF
$ fmt
= 0
