summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/tests/ui/borrow_deref_ref.stderr
blob: d72de37c69ff538a6eda4b77be4ae22a3d0c6a43 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
error: deref on an immutable reference
  --> $DIR/borrow_deref_ref.rs:10:17
   |
LL |         let b = &*a;
   |                 ^^^ help: if you would like to reborrow, try removing `&*`: `a`
   |
   = note: `-D clippy::borrow-deref-ref` implied by `-D warnings`

error: deref on an immutable reference
  --> $DIR/borrow_deref_ref.rs:12:22
   |
LL |         let b = &mut &*bar(&12);
   |                      ^^^^^^^^^^ help: if you would like to reborrow, try removing `&*`: `bar(&12)`

error: deref on an immutable reference
  --> $DIR/borrow_deref_ref.rs:55:23
   |
LL |         let addr_y = &&*x as *const _ as usize; // assert ok
   |                       ^^^ help: if you would like to reborrow, try removing `&*`: `x`

error: aborting due to 3 previous errors