summaryrefslogtreecommitdiffstats
path: root/src/test/ui/let-else/let-else-destructuring.stderr
blob: 7d6cb2386440d56b5926eed294a4a9ec3f0e6a33 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
error: <assignment> ... else { ... } is not allowed
  --> $DIR/let-else-destructuring.rs:10:9
   |
LL |         &Foo::Nested(Some(value)) = value else { break };
   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error[E0070]: invalid left-hand side of assignment
  --> $DIR/let-else-destructuring.rs:10:35
   |
LL |         &Foo::Nested(Some(value)) = value else { break };
   |         ------------------------- ^
   |         |
   |         cannot assign to this expression

error: aborting due to 2 previous errors

For more information about this error, try `rustc --explain E0070`.