WannabeBool protocol (Wannabe Bool v0.1.3) View Source
WannabeBool protocol is responsible for converting a structure to a boolean value.
The only function required to be implemented is to_boolean/1, which does the conversion.
The is_boolean/1 function is implemented for Atom, BitString, Integer and Float.
Link to this section Summary
Functions
Converts term to a boolean.
Link to this section Types
Specs
t() :: term()