Lines Matching refs:set
31 c.set(90).unwrap();
65 s.set("hello".to_string()).unwrap();
90 cell.set("hello".to_string()).unwrap();
98 cell.set("hello".to_string()).unwrap();
106 called.set(called.get() + 1);
125 called.set(called.get() + 1);
144 called.set(called.get() + 1);
160 called.set(called.get() + 1);
222 x.set(42).unwrap();
224 let _ = x.set(27); // <-- temporary (unique) borrow of inner `Option<T>` |
235 dangling_ref.set(Some(r));
247 cell.set(&s).unwrap();
291 c.set(90).unwrap();
299 c.set(92).unwrap();
339 s.set("hello".to_string()).unwrap();
368 s.spawn(|_| cell.set("hello".to_string()));
418 cell.set("hello".to_string()).unwrap();
426 cell.set(vec!["hello", "world"]).unwrap();
476 dangling_ref.set(Some(r));
654 let _ = scope.spawn(|_| cell.set(MSG.to_owned()));
688 cell.set(&s).unwrap();
744 assert!(cell.set(val1).is_ok());
747 assert!(cell.set(val2).is_err());
821 assert!(cell.set(false).is_ok());
824 assert!(cell.set(true).is_err());
913 assert!(cell.set(Box::new(heap.new_pebble("hello"))).is_ok());
917 assert!(cell.set(Box::new(heap.new_pebble("world"))).is_err());