mirror of
https://github.com/servo/servo.git
synced 2025-08-05 21:50:18 +01:00
Auto merge of #8597 - r0e:testing, r=Manishearth
Fix for #8593 'loop..match' should be 'while let' As per #8593. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8597) <!-- Reviewable:end -->
This commit is contained in:
commit
e3eee5a41b
3 changed files with 29 additions and 47 deletions
|
@ -1169,24 +1169,19 @@ impl BlockFlow {
|
|||
|
||||
// Can't use `for` because we assign to
|
||||
// `candidate_block_size_iterator.candidate_value`.
|
||||
loop {
|
||||
match candidate_block_size_iterator.next() {
|
||||
Some(block_size_used_val) => {
|
||||
solution = Some(
|
||||
BSizeConstraintSolution::solve_vertical_constraints_abs_nonreplaced(
|
||||
block_size_used_val,
|
||||
margin_block_start,
|
||||
margin_block_end,
|
||||
block_start,
|
||||
block_end,
|
||||
content_block_size,
|
||||
available_block_size));
|
||||
while let Some(block_size_used_val) = candidate_block_size_iterator.next() {
|
||||
solution = Some(
|
||||
BSizeConstraintSolution::solve_vertical_constraints_abs_nonreplaced(
|
||||
block_size_used_val,
|
||||
margin_block_start,
|
||||
margin_block_end,
|
||||
block_start,
|
||||
block_end,
|
||||
content_block_size,
|
||||
available_block_size));
|
||||
|
||||
candidate_block_size_iterator.candidate_value
|
||||
= solution.unwrap().block_size;
|
||||
}
|
||||
None => break,
|
||||
}
|
||||
candidate_block_size_iterator.candidate_value
|
||||
= solution.unwrap().block_size;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue