aboutsummaryrefslogtreecommitdiffstats
path: root/components/layout_2020/lib.rs
diff options
context:
space:
mode:
authorSimon Sapin <simon.sapin@exyr.org>2019-11-26 11:24:53 +0100
committerSimon Sapin <simon.sapin@exyr.org>2019-11-26 15:42:27 +0100
commit80eec48d373f89415e95e01ab9aaf6d07ac01c3e (patch)
treeadc07d7cde9453e3c4a5f1637d828f569cdc5dae /components/layout_2020/lib.rs
parentb2b3ea992c2f045a49d7264df18f5f85b2c913fb (diff)
downloadservo-80eec48d373f89415e95e01ab9aaf6d07ac01c3e.tar.gz
servo-80eec48d373f89415e95e01ab9aaf6d07ac01c3e.zip
Use std::mem::take instead of defining it
Diffstat (limited to 'components/layout_2020/lib.rs')
-rw-r--r--components/layout_2020/lib.rs9
1 files changed, 0 insertions, 9 deletions
diff --git a/components/layout_2020/lib.rs b/components/layout_2020/lib.rs
index 06db3b65acb..f1b3c308be2 100644
--- a/components/layout_2020/lib.rs
+++ b/components/layout_2020/lib.rs
@@ -81,12 +81,3 @@ fn relative_adjustement(
block: adjust(box_offsets.block_start, box_offsets.block_end),
}
}
-
-// FIXME: use std::mem::take when it’s stable.
-// https://github.com/rust-lang/rust/issues/61129
-fn take<T>(x: &mut T) -> T
-where
- T: Default,
-{
- std::mem::replace(x, Default::default())
-}