rustc: Remove all usage of manual deref()
Favor using '*' instead
This commit is contained in:
parent
76f0b1ad1f
commit
3fb1ed0e04
27 changed files with 61 additions and 68 deletions
|
|
@ -40,7 +40,7 @@ fn main()
|
|||
//~^ ERROR cannot pack type `~B`, which does not fulfill `Send`
|
||||
let v = Rc::new(RefCell::new(a));
|
||||
let w = v.clone();
|
||||
let b = v.deref();
|
||||
let b = &*v;
|
||||
let mut b = b.borrow_mut();
|
||||
b.v.set(w.clone());
|
||||
}
|
||||
|
|
|
|||
|
|
@ -20,5 +20,5 @@ pub fn main() {
|
|||
|
||||
let mut x = Rc::new(3);
|
||||
x = x;
|
||||
assert!(*x.deref() == 3);
|
||||
assert!(*x == 3);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue