Navigation
Synopsis Convert a Boolean value to integer.
Function int toInt(bool b)
Usage import Boolean;
Description Maps true to 1 and false to 0.
Examples
rascal>import Boolean;
ok
rascal>toInt(true);
int: 1
rascal>toInt(false);
int: 0
Is this page unclear, or have you spotted an error? Please add a comment below and help us to improve it. For all other questions and remarks, visit ask.rascal-mpl.org.