Function std::bool::to_bit

pub fn to_bit(v: bool) -> u8

Convert a bool to a u8.

Examples

rusti> std::bool::to_bit(true)
1
rusti> std::bool::to_bit(false)
0