Home
last modified time | relevance | path

Searched refs:InsertError (Results 1 – 3 of 3) sorted by relevance

/linux/rust/kernel/alloc/kvec/
H A Derrors.rs45 pub enum InsertError<T> {
52 impl<T> fmt::Debug for InsertError<T> { in fmt()
55 InsertError::IndexOutOfBounds(_) => write!(f, "Index out of bounds"),
56 InsertError::OutOfCapacity(_) => write!(f, "Not enough capacity"),
61 impl<T> From<InsertError<T>> for Error {
63 fn from(_: InsertError<T>) -> Error {
41 pub enum InsertError<T> { global() enum
48 impl<T> fmt::Debug for InsertError<T> { global() implementation
/linux/rust/kernel/
H A Dmaple_tree.rs121 pub fn insert(&self, index: usize, value: T, gfp: Flags) -> Result<(), InsertError<T>> { in insert()
169 pub fn insert_range<R>(&self, range: R, value: T, gfp: Flags) -> Result<(), InsertError<T>> in insert_range()
174 return Err(InsertError { in insert_range()
198 Err(InsertError { value, cause }) in insert_range()
585 pub struct InsertError<T> { struct
614 impl<T> From<InsertError<T>> for Error {
616 fn from(insert_err: InsertError<T>) -> Error { in from()
/linux/rust/kernel/alloc/
H A Dkvec.rs55 pub use self::errors::{InsertError, PushError, RemoveError};
409 /// use kernel::alloc::kvec::InsertError; in insert_within_capacity()
416 /// assert!(matches!(v.insert_within_capacity(0, 5), Err(InsertError::OutOfCapacity(_)))); in insert_within_capacity()
417 /// assert!(matches!(v.insert_within_capacity(1000, 5), Err(InsertError::IndexOutOfBounds(_)))); in insert_within_capacity()
425 ) -> Result<(), InsertError<T>> { in insert_within_capacity()
428 return Err(InsertError::IndexOutOfBounds(element));
432 return Err(InsertError::OutOfCapacity(element));