Trait otter_api_tests::imports::failure::_core::slice::SlicePattern[][src]

pub trait SlicePattern {
    type Item;
    fn as_slice(&self) -> &[Self::Item]

Notable traits for &'_ [u8]

impl<'_> Read for &'_ [u8]impl<'_> Write for &'_ mut [u8]
; }
🔬 This is a nightly-only experimental API. (slice_pattern)

stopgap trait for slice patterns

Expand description

Patterns in slices - currently, only used by strip_prefix and strip_suffix. At a future point, we hope to generalise core::str::Pattern (which at the time of writing is limited to str) to slices, and then this trait will be replaced or abolished.

Associated Types

🔬 This is a nightly-only experimental API. (slice_pattern)

stopgap trait for slice patterns

The element type of the slice being matched on.

Required methods

🔬 This is a nightly-only experimental API. (slice_pattern)

stopgap trait for slice patterns

Currently, the consumers of SlicePattern need a slice.

Implementations on Foreign Types

🔬 This is a nightly-only experimental API. (slice_pattern)

stopgap trait for slice patterns

🔬 This is a nightly-only experimental API. (slice_pattern)

stopgap trait for slice patterns

🔬 This is a nightly-only experimental API. (slice_pattern)

stopgap trait for slice patterns

🔬 This is a nightly-only experimental API. (slice_pattern)

stopgap trait for slice patterns

Implementors