mirror of
https://github.com/servo/servo.git
synced 2025-08-06 06:00:15 +01:00
Auto merge of #11778 - avadacatavra:mutflowlistdoubleiter, r=Ms2ger
Added DoubleEndedIterator for MutFlowListIterator <!-- Please describe your changes on the following line: --> Added DoubleEndedIterator for MutFlowListIterator --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: --> - [X ] `./mach build -d` does not report any errors - [X ] `./mach test-tidy` does not report any errors - [ ] These changes fix #__ (github issue number if applicable). <!-- Either: --> - [ ] There are tests for these changes OR - [ ] These changes do not require tests because _____ <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. --> <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/11778) <!-- Reviewable:end -->
This commit is contained in:
commit
324548f9b6
1 changed files with 6 additions and 0 deletions
|
@ -117,6 +117,12 @@ impl<'a> DoubleEndedIterator for FlowListIterator<'a> {
|
|||
}
|
||||
}
|
||||
|
||||
impl<'a> DoubleEndedIterator for MutFlowListIterator<'a> {
|
||||
fn next_back(&mut self) -> Option<&'a mut Flow> {
|
||||
self.it.next_back().map(flow_ref::deref_mut)
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a> Iterator for MutFlowListIterator<'a> {
|
||||
type Item = &'a mut Flow;
|
||||
#[inline]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue