Struct std::collections::hash_map::OccupiedError
source · pub struct OccupiedError<'a, K: 'a, V: 'a> {
pub entry: OccupiedEntry<'a, K, V>,
pub value: V,
}
🔬This is a nightly-only experimental API. (
map_try_insert
#82766)Expand description
当键已经存在时,由 try_insert
返回的错误。
包含占用的条目和未插入的值。
Fields§
§entry: OccupiedEntry<'a, K, V>
🔬This is a nightly-only experimental API. (
map_try_insert
#82766)map 中已被占用的条目。
value: V
🔬This is a nightly-only experimental API. (
map_try_insert
#82766)未插入的值,因为该条目已被占用。
Trait Implementations§
source§impl<'a, K: Debug, V: Debug> Error for OccupiedError<'a, K, V>
impl<'a, K: Debug, V: Debug> Error for OccupiedError<'a, K, V>
Auto Trait Implementations§
impl<'a, K, V> RefUnwindSafe for OccupiedError<'a, K, V>where K: RefUnwindSafe, V: RefUnwindSafe,
impl<'a, K, V> Send for OccupiedError<'a, K, V>where K: Send, V: Send,
impl<'a, K, V> Sync for OccupiedError<'a, K, V>where K: Sync, V: Sync,
impl<'a, K, V> Unpin for OccupiedError<'a, K, V>where K: Unpin, V: Unpin,
impl<'a, K, V> !UnwindSafe for OccupiedError<'a, K, V>
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
从拥有的值中借用。 Read more