pub enum IndexConvention {
None,
Byte,
Codepoint,
}Expand description
Which index convention a builtin’s integer positions use. Recorded so the stdlib reference states it and a runtime test checks it; it is documentation, not a semantic switch (#778).
Variants§
None
No integer positions in the signature.
Byte
Positions and lengths count UTF-8 bytes.
Codepoint
Positions and lengths count Unicode scalar values.
Trait Implementations§
Source§impl Clone for IndexConvention
impl Clone for IndexConvention
Source§fn clone(&self) -> IndexConvention
fn clone(&self) -> IndexConvention
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for IndexConvention
Source§impl Debug for IndexConvention
impl Debug for IndexConvention
impl Eq for IndexConvention
Source§impl PartialEq for IndexConvention
impl PartialEq for IndexConvention
impl StructuralPartialEq for IndexConvention
Auto Trait Implementations§
impl Freeze for IndexConvention
impl RefUnwindSafe for IndexConvention
impl Send for IndexConvention
impl Sync for IndexConvention
impl Unpin for IndexConvention
impl UnsafeUnpin for IndexConvention
impl UnwindSafe for IndexConvention
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.