Chris Morgan
›
Git
›
anymap
› commitdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
patch
|
inline
| side by side (from parent 1:
326bc69
)
commit
grep
author
committer
pickaxe
?
search:
re
Use namespaced enum variants for the map-entry slots.
author
Robert Straw
<drbawb@fatalsyntax.com>
Mon, 22 Dec 2014 15:33:25 +0000
committer
Robert Straw
<drbawb@fatalsyntax.com>
Mon, 22 Dec 2014 15:33:25 +0000
src/lib.rs
patch
|
blob
|
history
diff --git
a/src/lib.rs
b/src/lib.rs
index 3d47f0d45ce6c83d70beed766f7ac8f0ef204bd5..24c4620334df6a9b31235e427ca23d9bf6ec5122 100644
(file)
--- a/
src/lib.rs
+++ b/
src/lib.rs
@@
-188,8
+188,8
@@
impl AnyMap {
/// Gets the given key's corresponding entry in the map for in-place manipulation
pub fn entry<T: Any + 'static>(&mut self) -> Entry<T> {
match self.data.entry(TypeId::of::<T>()) {
/// Gets the given key's corresponding entry in the map for in-place manipulation
pub fn entry<T: Any + 'static>(&mut self) -> Entry<T> {
match self.data.entry(TypeId::of::<T>()) {
- hash_map::Occupied(e) => Occupied(OccupiedEntry { entry: e }),
- hash_map::Vacant(e) => Vacant(VacantEntry { entry: e }),
+ hash_map::
Entry::
Occupied(e) => Occupied(OccupiedEntry { entry: e }),
+ hash_map::
Entry::
Vacant(e) => Vacant(VacantEntry { entry: e }),
}
}
}
}