pub type PyUtf8StrInterned = PyInterned<PyUtf8Str>;Expand description
Interned PyUtf8Str — guaranteed UTF-8 at type level.
Same layout as PyStrInterned due to #[repr(transparent)] on both
PyInterned<T> and PyUtf8Str.
Aliased Type§
pub struct PyUtf8StrInterned { /* private fields */ }Implementations§
Source§impl PyUtf8StrInterned
impl PyUtf8StrInterned
Sourcepub fn as_interned_str(&self) -> &PyStrInterned
pub fn as_interned_str(&self) -> &PyStrInterned
View as PyStrInterned (widening: UTF-8 → WTF-8).
Sourcepub unsafe fn from_str_interned_unchecked(s: &PyStrInterned) -> &Self
pub unsafe fn from_str_interned_unchecked(s: &PyStrInterned) -> &Self
Narrow a PyStrInterned to PyUtf8StrInterned.
§Safety
The caller must ensure that the interned string is valid UTF-8.