Struct mm0_util::ArcList [−][src]
pub struct ArcList<T>(_);
A linked list data structure based on Arc
.
Implementations
impl<T> ArcList<T>
[src]
#[must_use]pub fn is_empty(&self) -> bool
[src]
#[must_use]
pub fn is_empty(&self) -> boolReturn true if the list is empty.
#[must_use]pub fn push(self, t: T) -> Self
[src]
#[must_use]
pub fn push(self, t: T) -> SelfAppend a new node on the end of the list.
#[must_use]pub fn contains(&self, t: &T) -> bool where
T: PartialEq,
[src]
#[must_use]
pub fn contains(&self, t: &T) -> bool whereT: PartialEq,
Check if the list contains an item.
#[must_use]pub fn join(&self, t: T, tail: Self) -> Self where
T: PartialEq + Clone,
[src]
#[must_use]
pub fn join(&self, t: T, tail: Self) -> Self whereT: PartialEq + Clone,
Construct self[..t2] ++ t :: tail
where t2
is the first element of self
equal to t
.
Panics if no such t2
exists (i.e. self.contains(t)
is a precondition).
Trait Implementations
impl<T> Clone for ArcList<T>
[src]
fn clone(&self) -> Self
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<T: Debug> Debug for ArcList<T>
[src]
impl<T> Default for ArcList<T>
[src]
impl<'a, T> IntoIterator for &'a ArcList<T>
[src]
type Item = &'a T
The type of the elements being iterated over.
type IntoIter = ArcListIter<'a, T>
Which kind of iterator are we turning this into?
fn into_iter(self) -> ArcListIter<'a, T>ⓘNotable traits for ArcListIter<'a, T>
impl<'a, T> Iterator for ArcListIter<'a, T> type Item = &'a T;
[src]
Notable traits for ArcListIter<'a, T>
impl<'a, T> Iterator for ArcListIter<'a, T> type Item = &'a T;
Auto Trait Implementations
impl<T> RefUnwindSafe for ArcList<T> where
T: RefUnwindSafe,
T: RefUnwindSafe,
impl<T> Send for ArcList<T> where
T: Send + Sync,
T: Send + Sync,
impl<T> Sync for ArcList<T> where
T: Send + Sync,
T: Send + Sync,
impl<T> Unpin for ArcList<T>
impl<T> UnwindSafe for ArcList<T> where
T: RefUnwindSafe,
T: RefUnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Erased for T
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,