mirror of
https://github.com/servo/servo.git
synced 2025-08-12 00:45:33 +01:00
style: Fix clippy warnings
Depends on D96634 Differential Revision: https://phabricator.services.mozilla.com/D96636
This commit is contained in:
parent
191d5226a3
commit
a95ce79554
6 changed files with 13 additions and 16 deletions
|
@ -37,7 +37,7 @@ pub struct NthIndexCacheInner(FxHashMap<OpaqueElement, i32>);
|
|||
impl NthIndexCacheInner {
|
||||
/// Does a lookup for a given element in the cache.
|
||||
pub fn lookup(&mut self, el: OpaqueElement) -> Option<i32> {
|
||||
self.0.get(&el).map(|x| *x)
|
||||
self.0.get(&el).copied()
|
||||
}
|
||||
|
||||
/// Inserts an entry into the cache.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue