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/flow/construct.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/flow/construct.rs')
-rw-r--r-- | components/layout_2020/flow/construct.rs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/components/layout_2020/flow/construct.rs b/components/layout_2020/flow/construct.rs index 52724eb121f..57d7bf9dd31 100644 --- a/components/layout_2020/flow/construct.rs +++ b/components/layout_2020/flow/construct.rs @@ -10,7 +10,6 @@ use crate::flow::{BlockContainer, BlockFormattingContext, BlockLevelBox}; use crate::formatting_contexts::IndependentFormattingContext; use crate::positioned::AbsolutelyPositionedBox; use crate::style_ext::{DisplayGeneratingBox, DisplayInside, DisplayOutside}; -use crate::take; use rayon::iter::{IntoParallelIterator, ParallelIterator}; use rayon_croissant::ParallelIteratorExt; use servo_arc::Arc; @@ -381,7 +380,7 @@ where // The fragmented boxes before the block level element // are obviously not the last fragment. last_fragment: false, - children: take(&mut ongoing.children), + children: std::mem::take(&mut ongoing.children), }; ongoing.first_fragment = false; fragmented @@ -516,7 +515,7 @@ where let box_ = IntermediateBlockLevelBox::SameFormattingContextBlock { style: anonymous_style.clone(), - contents: IntermediateBlockContainer::InlineFormattingContext(take( + contents: IntermediateBlockContainer::InlineFormattingContext(std::mem::take( &mut self.ongoing_inline_formatting_context, )), }; |