blob: 69f5953deb22335851091b70a59aa1e35b07d4ee (
plain)
1
2
3
4
5
6
7
8
|
fn main() {
match Some(()) {
None => { },
option if { option = None; false } => { }, //~ ERROR E0302
//~^ ERROR cannot assign to `option`, as it is immutable for the pattern guard
Some(_) => { }
}
}
|