#[repr(transparent)]pub struct StringRef(pub ThinStr<'static>);Expand description
Represents a handle to a string that can be retrieved by the string set. The exact representation is not a public detail; it is only available so that it is known for FFI size and alignment.
Some StringRefs refer to well-known strings, which always exist in
every string table.
The caller needs to ensure the string set it was created from always exists when a StringId is dereferenced.
Tuple Fields§
§0: ThinStr<'static>Implementations§
Trait Implementations§
impl Copy for StringRef
impl Eq for StringRef
impl StructuralPartialEq for StringRef
Auto Trait Implementations§
impl Freeze for StringRef
impl RefUnwindSafe for StringRef
impl Send for StringRef
impl Sync for StringRef
impl Unpin for StringRef
impl UnwindSafe for StringRef
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.