mirror of
https://github.com/servo/servo.git
synced 2025-07-22 14:53:49 +01:00
Clippy: Fixed some clippy warnings (#31818)
* Fixed clippy warnings * made changes for lowercase characters. * changed is_lowercase() to is_ascii_lowercase() * added std library function `is_ascii_uppercase()` and `is_ascii_lowercase()` * made recommended changes
This commit is contained in:
parent
3c05b58221
commit
566fd475d9
11 changed files with 57 additions and 68 deletions
|
@ -195,7 +195,7 @@ impl HTMLCollection {
|
|||
None => elem.local_name() == qualified_name,
|
||||
Some(prefix) => {
|
||||
qualified_name.starts_with(&**prefix) &&
|
||||
qualified_name.find(":") == Some(prefix.len()) &&
|
||||
qualified_name.find(':') == Some(prefix.len()) &&
|
||||
qualified_name.ends_with(&**elem.local_name())
|
||||
},
|
||||
}
|
||||
|
@ -295,7 +295,7 @@ impl HTMLCollection {
|
|||
.filter(move |element| self.filter.filter(element, &self.root))
|
||||
}
|
||||
|
||||
pub fn elements_iter<'a>(&'a self) -> impl Iterator<Item = DomRoot<Element>> + 'a {
|
||||
pub fn elements_iter(&self) -> impl Iterator<Item = DomRoot<Element>> + '_ {
|
||||
// Iterate forwards from the root.
|
||||
self.elements_iter_after(&self.root)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue