difftreelog
perf do not fill assertions_ran map without asserts
in: master
1 file changed
crates/jrsonnet-evaluator/src/obj.rsdiffbeforeafterboth472 }472 }473473474 fn run_assertions_raw(&self, real_this: &Self) -> Result<()> {474 fn run_assertions_raw(&self, real_this: &Self) -> Result<()> {475 if self.0.assertions.is_empty() {476 if let Some(super_obj) = &self.0.sup {477 super_obj.run_assertions_raw(real_this)?;478 }479 return Ok(());480 }475 if self.0.assertions_ran.borrow_mut().insert(real_this.clone()) {481 if self.0.assertions_ran.borrow_mut().insert(real_this.clone()) {476 for assertion in self.0.assertions.iter() {482 for assertion in self.0.assertions.iter() {477 if let Err(e) = assertion.run(self.0.sup.clone(), Some(real_this.clone())) {483 if let Err(e) = assertion.run(self.0.sup.clone(), Some(real_this.clone())) {