mirror of
https://github.com/servo/servo.git
synced 2025-07-23 23:33:43 +01:00
Fixed some clippy warnings in components (#32107)
* Fixed some clippy warnings in components * Updated handling of NaN values in comparison * Updated formatting using ./mach fmt
This commit is contained in:
parent
f70413baba
commit
007a72fe4d
9 changed files with 20 additions and 29 deletions
|
@ -719,15 +719,11 @@ impl Node {
|
|||
other: &Node,
|
||||
shadow_including: ShadowIncluding,
|
||||
) -> Option<DomRoot<Node>> {
|
||||
for ancestor in self.inclusive_ancestors(shadow_including) {
|
||||
if other
|
||||
self.inclusive_ancestors(shadow_including).find(|ancestor| {
|
||||
other
|
||||
.inclusive_ancestors(shadow_including)
|
||||
.any(|node| node == ancestor)
|
||||
{
|
||||
return Some(ancestor);
|
||||
}
|
||||
}
|
||||
None
|
||||
.any(|node| node == *ancestor)
|
||||
})
|
||||
}
|
||||
|
||||
pub fn is_inclusive_ancestor_of(&self, parent: &Node) -> bool {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue