Re-exports§
pub use ascii;
Modules§
Macros§
- ascii
- Creates an
AsciiStrfrom a string literal, throwing a compile error if the literal isn’t actually ascii.
Structs§
Enums§
Traits§
Functions§
- char_
range_ end - char_
to_ decimal - The decimal digit value of
ch, if it has one — CPython’sPy_UNICODE_TODECIMAL. - codepoint_
range_ end - expandtabs
- Replace all tabs in a string with spaces, using the given tab size.
- get_
chars - get_
codepoints - to_
ascii - Convert a string to ascii compatible, escaping unicode-s into escape sequences.
- transform_
decimal_ and_ space_ to_ ascii - Replace Unicode decimal digits with their ASCII equivalents and any Unicode
whitespace with a plain space, so the byte-oriented numeric parsers can read
them. Mirrors CPython’s
_PyUnicode_TransformDecimalAndSpaceToASCII. - try_
get_ chars - try_
get_ codepoints - zfill
- Returns
Nonefor a width whose result cannot be allocated.