]>
Commit | Line | Data |
---|---|---|
064997fb | 1 | error[E0381]: used binding `x` isn't initialized |
923072b8 FG |
2 | --> $DIR/type-check-2-2.rs:19:28 |
3 | | | |
064997fb FG |
4 | LL | let x: u64; |
5 | | - binding declared here but left uninitialized | |
923072b8 | 6 | LL | asm!("{}", in(reg) x); |
064997fb | 7 | | ^ `x` used here but it isn't initialized |
2b03887a FG |
8 | | |
9 | help: consider assigning a value | |
10 | | | |
11 | LL | let x: u64 = 0; | |
12 | | +++ | |
923072b8 | 13 | |
064997fb | 14 | error[E0381]: used binding `y` isn't initialized |
923072b8 FG |
15 | --> $DIR/type-check-2-2.rs:22:9 |
16 | | | |
064997fb FG |
17 | LL | let mut y: u64; |
18 | | ----- binding declared here but left uninitialized | |
923072b8 | 19 | LL | asm!("{}", inout(reg) y); |
064997fb | 20 | | ^^^^^^^^^^^^^^^^^^^^^^^^ `y` used here but it isn't initialized |
2b03887a FG |
21 | | |
22 | help: consider assigning a value | |
23 | | | |
24 | LL | let mut y: u64 = 0; | |
25 | | +++ | |
923072b8 FG |
26 | |
27 | error[E0596]: cannot borrow `v` as mutable, as it is not declared as mutable | |
28 | --> $DIR/type-check-2-2.rs:30:29 | |
29 | | | |
30 | LL | let v: Vec<u64> = vec![0, 1, 2]; | |
31 | | - help: consider changing this to be mutable: `mut v` | |
32 | LL | asm!("{}", in(reg) v[0]); | |
33 | LL | asm!("{}", out(reg) v[0]); | |
34 | | ^ cannot borrow as mutable | |
35 | ||
36 | error[E0596]: cannot borrow `v` as mutable, as it is not declared as mutable | |
37 | --> $DIR/type-check-2-2.rs:32:31 | |
38 | | | |
39 | LL | let v: Vec<u64> = vec![0, 1, 2]; | |
40 | | - help: consider changing this to be mutable: `mut v` | |
41 | ... | |
42 | LL | asm!("{}", inout(reg) v[0]); | |
43 | | ^ cannot borrow as mutable | |
44 | ||
45 | error: aborting due to 4 previous errors | |
46 | ||
47 | Some errors have detailed explanations: E0381, E0596. | |
48 | For more information about an error, try `rustc --explain E0381`. |