s/alt/match/... again.
This commit is contained in:
parent
4a216a000a
commit
0308884416
3 changed files with 8 additions and 8 deletions
|
@ -3,28 +3,28 @@ enum opts {
|
|||
}
|
||||
|
||||
fn matcher1(x: opts) {
|
||||
alt x {
|
||||
match x {
|
||||
a(ref i) | b(copy i) => {} //~ ERROR variable `i` is bound with different mode in pattern #2 than in pattern #1
|
||||
c(_) => {}
|
||||
}
|
||||
}
|
||||
|
||||
fn matcher2(x: opts) {
|
||||
alt x {
|
||||
match x {
|
||||
a(ref i) | b(i) => {} //~ ERROR variable `i` is bound with different mode in pattern #2 than in pattern #1
|
||||
c(_) => {}
|
||||
}
|
||||
}
|
||||
|
||||
fn matcher3(x: opts) {
|
||||
alt x {
|
||||
match x {
|
||||
a(ref mut i) | b(ref const i) => {} //~ ERROR variable `i` is bound with different mode in pattern #2 than in pattern #1
|
||||
c(_) => {}
|
||||
}
|
||||
}
|
||||
|
||||
fn matcher4(x: opts) {
|
||||
alt x {
|
||||
match x {
|
||||
a(ref mut i) | b(ref i) => {} //~ ERROR variable `i` is bound with different mode in pattern #2 than in pattern #1
|
||||
c(_) => {}
|
||||
}
|
||||
|
@ -32,10 +32,10 @@ fn matcher4(x: opts) {
|
|||
|
||||
|
||||
fn matcher5(x: opts) {
|
||||
alt x {
|
||||
match x {
|
||||
a(ref i) | b(ref i) => {}
|
||||
c(_) => {}
|
||||
}
|
||||
}
|
||||
|
||||
fn main() {}
|
||||
fn main() {}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue