diff options
author | Simon Sapin <simon.sapin@exyr.org> | 2019-11-26 11:24:53 +0100 |
---|---|---|
committer | Simon Sapin <simon.sapin@exyr.org> | 2019-11-26 15:42:27 +0100 |
commit | 80eec48d373f89415e95e01ab9aaf6d07ac01c3e (patch) | |
tree | adc07d7cde9453e3c4a5f1637d828f569cdc5dae /components/layout_2020/lib.rs | |
parent | b2b3ea992c2f045a49d7264df18f5f85b2c913fb (diff) | |
download | servo-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.rs | 9 |
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()) -} |