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

Method to_trail_surrogate

crates/wtf8/src/lib.rs:141–146  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

139 /// Returns the numeric value of the code point if it is a trailing surrogate.
140 #[inline]
141 pub const fn to_trail_surrogate(self) -> Option<TrailSurrogate> {
142 match self.value {
143 trail @ 0xDC00..=0xDFFF => Some(TrailSurrogate(trail as u16)),
144 _ => None,
145 }
146 }
147
148 /// Optionally returns a Unicode scalar value for the code point.
149 ///

Callers 1

scanstringFunction · 0.80

Calls 2

TrailSurrogateClass · 0.85
SomeClass · 0.50

Tested by

no test coverage detected