2019-08-02 17:08:16 -07:00
|
|
|
// Test that we don't allow partial initialization.
|
|
|
|
// This may be relaxed in the future (see #54987).
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
let mut t: (u64, u64);
|
|
|
|
t.0 = 1;
|
2022-06-21 11:57:45 -07:00
|
|
|
//~^ ERROR E0381
|
2019-08-02 17:08:16 -07:00
|
|
|
t.1 = 1;
|
|
|
|
|
|
|
|
let mut t: (u64, u64);
|
|
|
|
t.1 = 1;
|
2022-06-21 11:57:45 -07:00
|
|
|
//~^ ERROR E0381
|
2019-08-02 17:08:16 -07:00
|
|
|
t.0 = 1;
|
|
|
|
|
|
|
|
let mut t: (u64, u64);
|
|
|
|
t.0 = 1;
|
2022-06-21 11:57:45 -07:00
|
|
|
//~^ ERROR E0381
|
2019-08-02 17:08:16 -07:00
|
|
|
|
|
|
|
let mut t: (u64,);
|
|
|
|
t.0 = 1;
|
2022-06-21 11:57:45 -07:00
|
|
|
//~^ ERROR E0381
|
2019-08-02 17:08:16 -07:00
|
|
|
}
|