File tree Expand file tree Collapse file tree 2 files changed +21
-2
lines changed
trunk/src/librustc_resolve Expand file tree Collapse file tree 2 files changed +21
-2
lines changed Original file line number Diff line number Diff line change 1
1
---
2
- refs/heads/master: 4840c13f1ae38a6d6b2c3068a7a066ea4af30b11
2
+ refs/heads/master: 378aba4743f8f26747829fd5da1ab1037ead11d9
3
3
refs/heads/snap-stage3: a5c12f4e39d32af3c951b66bd2839bc0b5a1125b
4
4
refs/heads/try: b53c0f93eedcdedd4fd89bccc5a3a09d1c5cd23e
5
5
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
Original file line number Diff line number Diff line change @@ -473,6 +473,26 @@ fn foo(f: i32, g: i32) {} // ok!
473
473
```
474
474
"## ,
475
475
476
+ E0416 : r##"
477
+ An identifier is bound more than once in a pattern. Example of erroneous
478
+ code:
479
+
480
+ ```
481
+ match (1, 2) {
482
+ (x, x) => {} // error: identifier `x` is bound more than once in the
483
+ // same pattern
484
+ }
485
+ ```
486
+
487
+ Please verify you didn't misspell identifiers' name. Example:
488
+
489
+ ```
490
+ match (1, 2) {
491
+ (x, y) => {} // ok!
492
+ }
493
+ ```
494
+ "## ,
495
+
476
496
E0417 : r##"
477
497
A static variable was referenced in a pattern. Example of erroneous code:
478
498
@@ -796,7 +816,6 @@ register_diagnostics! {
796
816
E0410 , // variable from pattern is not bound in pattern 1
797
817
E0411 , // use of `Self` outside of an impl or trait
798
818
E0414 , // only irrefutable patterns allowed here
799
- E0416 , // identifier is bound more than once in the same pattern
800
819
E0418 , // is not an enum variant, struct or const
801
820
E0420 , // is not an associated const
802
821
E0421 , // unresolved associated const
You can’t perform that action at this time.
0 commit comments