added mcarton's test suggestion
This commit is contained in:
parent
46491443ff
commit
1b112f96b8
1 changed files with 5 additions and 0 deletions
|
|
@ -176,6 +176,11 @@ fn if_same_then_else() -> Result<&'static str, ()> {
|
|||
None => 24, //~ERROR this `match` has identical arm bodies
|
||||
};
|
||||
|
||||
let _ = match Some(42) {
|
||||
Some(foo) => 24,
|
||||
None => 24,
|
||||
};
|
||||
|
||||
let _ = match Some(42) {
|
||||
Some(42) => 24,
|
||||
Some(a) => 24, // bindings are different
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue