Rollup merge of #85436 - tamird:save-clone, r=estebank
Avoid cloning cache key r? `@estebank`
This commit is contained in:
commit
b3bcf4af74
1 changed files with 2 additions and 3 deletions
|
@ -342,7 +342,7 @@ impl<O: ForestObligation> ObligationForest<O> {
|
||||||
return Ok(());
|
return Ok(());
|
||||||
}
|
}
|
||||||
|
|
||||||
match self.active_cache.entry(cache_key.clone()) {
|
match self.active_cache.entry(cache_key) {
|
||||||
Entry::Occupied(o) => {
|
Entry::Occupied(o) => {
|
||||||
let node = &mut self.nodes[*o.get()];
|
let node = &mut self.nodes[*o.get()];
|
||||||
if let Some(parent_index) = parent {
|
if let Some(parent_index) = parent {
|
||||||
|
@ -366,8 +366,7 @@ impl<O: ForestObligation> ObligationForest<O> {
|
||||||
&& self
|
&& self
|
||||||
.error_cache
|
.error_cache
|
||||||
.get(&obligation_tree_id)
|
.get(&obligation_tree_id)
|
||||||
.map(|errors| errors.contains(&cache_key))
|
.map_or(false, |errors| errors.contains(v.key()));
|
||||||
.unwrap_or(false);
|
|
||||||
|
|
||||||
if already_failed {
|
if already_failed {
|
||||||
Err(())
|
Err(())
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue