]> git.lizzy.rs Git - rust.git/blobdiff - src/librustdoc/clean/mod.rs
Convert more usages over
[rust.git] / src / librustdoc / clean / mod.rs
index 3fe048a6986bb2e0bb33d70e7888560ea2226ab8..8fec433e56de6d5c65bbbba04701f605103c32d1 100644 (file)
@@ -4408,7 +4408,7 @@ pub fn enter_impl_trait<F, R>(cx: &DocContext<'_>, f: F) -> R
 where
     F: FnOnce() -> R,
 {
-    let old_bounds = mem::replace(&mut *cx.impl_trait_bounds.borrow_mut(), Default::default());
+    let old_bounds = mem::take(&mut *cx.impl_trait_bounds.borrow_mut());
     let r = f();
     assert!(cx.impl_trait_bounds.borrow().is_empty());
     *cx.impl_trait_bounds.borrow_mut() = old_bounds;