diff options
author | Johannes Linke <johannes.linke@posteo.de> | 2016-01-02 16:51:01 +0100 |
---|---|---|
committer | Johannes Linke <johannes.linke@posteo.de> | 2016-01-02 23:27:15 +0100 |
commit | 6b215f38eefc98853244c2ec6f4187ae6f000417 (patch) | |
tree | cf4dbc65e6b6fa641359b713f91b596bf9f9a666 /components/layout/construct.rs | |
parent | b1ca3d1cdff412c5ae12113c3681f789becebabc (diff) | |
download | servo-6b215f38eefc98853244c2ec6f4187ae6f000417.tar.gz servo-6b215f38eefc98853244c2ec6f4187ae6f000417.zip |
Fix a bunch of clippy lints
Diffstat (limited to 'components/layout/construct.rs')
-rw-r--r-- | components/layout/construct.rs | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/components/layout/construct.rs b/components/layout/construct.rs index 6e6ea30332c..89c895ca4f2 100644 --- a/components/layout/construct.rs +++ b/components/layout/construct.rs @@ -1102,12 +1102,9 @@ impl<'a, 'ln, ConcreteThreadSafeLayoutNode: ThreadSafeLayoutNode<'ln>> node, caption_side::T::top); - match construction_result { - ConstructionResult::Flow(table_flow, table_abs_descendants) => { - wrapper_flow.add_new_child(table_flow); - abs_descendants.push_descendants(table_abs_descendants); - } - _ => {} + if let ConstructionResult::Flow(table_flow, table_abs_descendants) = construction_result { + wrapper_flow.add_new_child(table_flow); + abs_descendants.push_descendants(table_abs_descendants); } // If the value of `caption-side` is `bottom`, place it now. @@ -1271,12 +1268,9 @@ impl<'a, 'ln, ConcreteThreadSafeLayoutNode: ThreadSafeLayoutNode<'ln>> for kid in node.children() { // CSS 2.1 § 17.2.1. Treat all non-column child fragments of `table-column-group` // as `display: none`. - match kid.swap_out_construction_result() { - ConstructionResult::ConstructionItem(ConstructionItem::TableColumnFragment( - fragment)) => { - col_fragments.push(fragment); - } - _ => {} + if let ConstructionResult::ConstructionItem(ConstructionItem::TableColumnFragment(fragment)) + = kid.swap_out_construction_result() { + col_fragments.push(fragment) } } if col_fragments.is_empty() { |