Fix no-std preserve_order build

This commit is contained in:
David Tolnay 2020-09-30 13:30:31 -07:00
parent 4e0d3499ce
commit e8bb41c94c
No known key found for this signature in database
GPG Key ID: F9BA143B95FF6D82

View File

@ -174,7 +174,7 @@ impl Map<String, Value> {
#[inline]
pub fn append(&mut self, other: &mut Self) {
#[cfg(feature = "preserve_order")]
for (k, v) in std::mem::replace(&mut other.map, MapImpl::default()) {
for (k, v) in mem::replace(&mut other.map, MapImpl::default()) {
self.map.insert(k, v);
}
#[cfg(not(feature = "preserve_order"))]