Skip to main content

char_to_decimal

Function char_to_decimal 

Source
pub fn char_to_decimal(ch: char) -> Option<u8>
Expand description

The decimal digit value of ch, if it has one — CPython’s Py_UNICODE_TODECIMAL.

Reads the bundled character database, the same source unicodedata.decimal consults, so the two can never disagree and new scripts are picked up with the next Unicode update.