Type checking

A type-checking expression MUST evaluate to a boolean (true or false).

Syntax

typecheck_expression
expression is not type_expression
Show source
typecheck_expression
  = expression "is" "not"? type_expression

Example

42 is int;
42 is not string;
42 is (string | int);