diff options
Diffstat (limited to 'src/map.rs')
-rw-r--r-- | src/map.rs | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -14,12 +14,12 @@ //! [`BTreeMap`]: https://doc.rust-lang.org/std/collections/struct.BTreeMap.html //! [`LinkedHashMap`]: https://docs.rs/linked-hash-map/*/linked_hash_map/struct.LinkedHashMap.html +use crate::value::Value; use serde::{de, ser}; +use std::borrow::Borrow; use std::fmt::{self, Debug}; -use crate::value::Value; use std::hash::Hash; use std::iter::FromIterator; -use std::borrow::Borrow; use std::ops; #[cfg(not(feature = "preserve_order"))] @@ -144,10 +144,10 @@ impl Map<String, Value> { where S: Into<String>, { - #[cfg(not(feature = "preserve_order"))] - use std::collections::btree_map::Entry as EntryImpl; #[cfg(feature = "preserve_order")] use linked_hash_map::Entry as EntryImpl; + #[cfg(not(feature = "preserve_order"))] + use std::collections::btree_map::Entry as EntryImpl; match self.map.entry(key.into()) { EntryImpl::Vacant(vacant) => Entry::Vacant(VacantEntry { vacant: vacant }), |