fn new_cost_under_inv(&mut self, inv: PtrInvention, cost:i32, args: Option<Vec<Id>>) {
        if cost < self.inventionless_cost
                && (!self.inventionful_cost.contains_key(&inv) || cost < self.inventionful_cost[&inv].0)
        {
            self.inventionful_cost.insert(inv, (cost,args));
        }
    }
/// improve the cost using a new invention, or do nothing if we've already seen
/// a better cost for this invention. Also skip if inventionless cost is better.
improve the cost using a new invention, or do nothing if we've already seen
a better cost for this invention. Also skip if inventionless cost is better.
improve the cost using a new invention or do nothing if we ' ve already seen a better cost for this invention . Also skip if inventionless cost is better .
fn new_cost_under_inv(&mut self, inv: PtrInvention, cost:i32, args: Option<Vec<Id>>) {
        if cost < self.inventionless_cost
                && (!self.inventionful_cost.contains_key(&inv) || cost < self.inventionful_cost[&inv].0)
        {
            self.inventionful_cost.insert(inv, (cost,args));
        }
    }
fn new_cost_under_inv ( & mut self , inv : PtrInvention , cost : i32 , args : Option < Vec < Id > > ) { if cost < self . inventionless_cost && ( ! self . inventionful_cost . contains_key ( & inv ) || cost < self . inventionful_cost [ & inv ] . 0 ) { self . inventionful_cost . insert ( inv , ( cost , args ) ) ; } }
improve the cost using a new invention, or do nothing if we've already seen
a better cost for this invention.
improve the cost using a new invention or do nothing if we ' ve already seen a better cost for this invention .
&mut self
inv
PtrInvention
cost
i32
args
Option<Vec<Id>>
&mut self
inv
PtrInvention
cost
i32
args
Option<Vec<Id>>