use super::ConcurrentSlice;
use crate::elem::ConcurrentElement;
use orx_fixed_vec::IntoConcurrentPinnedVec;
impl<T, P> ConcurrentSlice<'_, T, P>
where
P: IntoConcurrentPinnedVec<ConcurrentElement<T>>,
T: PartialEq,
{
pub fn index_of(&self, value: &T) -> Option<usize> {
self.iter().position(|e| e == value)
}
pub fn contains(&self, value: &T) -> bool {
self.index_of(value).is_some()
}
}