summaryrefslogtreecommitdiffstats
path: root/third_party/rust/zerocopy/tests/ui-msrv/transmute-ref-src-not-a-reference.stderr
blob: 0f4aeec9e2455bbb10f258b7fc6ac73daaf0aaef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
error[E0308]: mismatched types
  --> tests/ui-msrv/transmute-ref-src-not-a-reference.rs:17:49
   |
17 | const SRC_NOT_A_REFERENCE: &u8 = transmute_ref!(0usize);
   |                                  ---------------^^^^^^-
   |                                  |              |
   |                                  |              expected reference, found `usize`
   |                                  |              help: consider borrowing here: `&0usize`
   |                                  expected due to this
   |
   = note: expected reference `&_`
                   found type `usize`