]> git.lizzy.rs Git - rust.git/blob - src/test/ui/bad/bad-expr-lhs.rs
Auto merge of #81507 - weiznich:add_diesel_to_cargo_test, r=Mark-Simulacrum
[rust.git] / src / test / ui / bad / bad-expr-lhs.rs
1 fn main() {
2     1 = 2; //~ ERROR invalid left-hand side of assignment
3     1 += 2; //~ ERROR invalid left-hand side of assignment
4     (1, 2) = (3, 4); //~ ERROR destructuring assignments are unstable
5     //~| ERROR invalid left-hand side of assignment
6     //~| ERROR invalid left-hand side of assignment
7
8     let (a, b) = (1, 2);
9     (a, b) = (3, 4); //~ ERROR destructuring assignments are unstable
10
11     None = Some(3); //~ ERROR invalid left-hand side of assignment
12 }