cannot assign to self.cart.parent_order_sign, which is behind a & reference self is a & reference, so the data it refers to cannot be written.
fn main() {let session = Session::new();let _ = get_effprod();}pub fn get_effprod(& self) -> bool {...self.cart.product_list.push(...); // 报错...}正确的写法:&后面加上mutpub fn get_effprod(&mut self) -> bool {...self.cart.product_list.push(...); // 报错...}
