MCPcopy Index your code
hub / github.com/RustPython/RustPython / upper_locate

Function upper_locate

crates/sre_engine/src/string.rs:385–390  ·  view source on GitHub ↗
(ch: u32)

Source from the content-addressed store, hash-verified

383}
384#[inline]
385pub(crate) fn upper_locate(ch: u32) -> u32 {
386 // FIXME: Ignore the locales
387 u8::try_from(ch)
388 .map(|x| x.to_ascii_uppercase() as u32)
389 .unwrap_or(ch)
390}
391#[inline]
392pub(crate) fn is_uni_digit(ch: u32) -> bool {
393 // TODO: check with cpython

Callers 2

char_loc_ignoreFunction · 0.85
charset_loc_ignoreFunction · 0.85

Calls 2

to_ascii_uppercaseMethod · 0.80
mapMethod · 0.45

Tested by

no test coverage detected