File tree Expand file tree Collapse file tree 1 file changed +24
-1
lines changed Expand file tree Collapse file tree 1 file changed +24
-1
lines changed Original file line number Diff line number Diff line change @@ -2791,6 +2791,30 @@ fn main() {
2791
2791
```
2792
2792
"## ,
2793
2793
2794
+ E0230 : r##"
2795
+ The trait has more type parameters specified than appear in its definition.
2796
+
2797
+ Erroneous example code:
2798
+
2799
+ ```compile_fail,E0230
2800
+ #![feature(on_unimplemented)]
2801
+ #[rustc_on_unimplemented = "Trait error on `{Self}` with `<{A},{B},{C}>`"]
2802
+ // error: there is no type parameter C on trait TraitWithThreeParams
2803
+ trait TraitWithThreeParams<A,B>
2804
+ {}
2805
+ ```
2806
+
2807
+ Include the correct number of type parameters and the compilation should
2808
+ proceed:
2809
+
2810
+ ```
2811
+ #![feature(on_unimplemented)]
2812
+ #[rustc_on_unimplemented = "Trait error on `{Self}` with `<{A},{B},{C}>`"]
2813
+ trait TraitWithThreeParams<A,B,C> // ok!
2814
+ {}
2815
+ ```
2816
+ "## ,
2817
+
2794
2818
E0232 : r##"
2795
2819
The attribute must have a value. Erroneous code example:
2796
2820
@@ -4116,7 +4140,6 @@ register_diagnostics! {
4116
4140
E0226 , // only a single explicit lifetime bound is permitted
4117
4141
E0227 , // ambiguous lifetime bound, explicit lifetime bound required
4118
4142
E0228 , // explicit lifetime bound required
4119
- E0230 , // there is no type parameter on trait
4120
4143
E0231 , // only named substitution parameters are allowed
4121
4144
// E0233,
4122
4145
// E0234,
You can’t perform that action at this time.
0 commit comments