Kernel.or
You're seeing just the macro
or
, go back to Kernel module for more information.
Strictly boolean "or" operator.
If left
is true
, returns true
; otherwise returns right
.
Requires only the left
operand to be a boolean since it short-circuits.
If the left
operand is not a boolean, a BadBooleanError
exception is
raised.
Allowed in guard tests.
Examples
iex> true or false
true
iex> false or 42
42
iex> 42 or false
** (BadBooleanError) expected a boolean on left-side of "or", got: 42