@@ -19,19 +19,24 @@ static TEST5: (_, _) = (1, 2);
1919
2020fn test6 ( _: _ ) { }
2121//~^ ERROR the type placeholder `_` is not allowed within types on item signatures
22+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
2223
2324fn test6_b < T > ( _: _ , _: T ) { }
2425//~^ ERROR the type placeholder `_` is not allowed within types on item signatures
26+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
2527
2628fn test6_c < T , K , L , A , B > ( _: _ , _: ( T , K , L , A , B ) ) { }
2729//~^ ERROR the type placeholder `_` is not allowed within types on item signatures
30+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
2831
2932fn test7 ( x : _ ) { let _x: usize = x; }
3033//~^ ERROR the type placeholder `_` is not allowed within types on item signatures
34+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
3135
3236fn test8 ( _f : fn ( ) -> _ ) { }
3337//~^ ERROR the type placeholder `_` is not allowed within types on item signatures
3438//~| ERROR the type placeholder `_` is not allowed within types on item signatures
39+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
3540
3641struct Test9 ;
3742
@@ -41,6 +46,7 @@ impl Test9 {
4146
4247 fn test10 ( & self , _x : _ ) { }
4348 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
49+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
4450}
4551
4652fn test11 ( x : & usize ) -> & _ {
@@ -59,12 +65,16 @@ impl Clone for Test9 {
5965
6066 fn clone_from ( & mut self , other : _ ) { * self = Test9 ; }
6167 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
68+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
6269}
6370
6471struct Test10 {
6572 a : _ ,
6673 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
74+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
6775 b : ( _ , _ ) ,
76+ //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
77+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
6878}
6979
7080pub fn main ( ) {
@@ -92,13 +102,16 @@ pub fn main() {
92102
93103 fn fn_test6 ( _: _ ) { }
94104 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
105+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
95106
96107 fn fn_test7 ( x : _ ) { let _x: usize = x; }
97108 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
109+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
98110
99111 fn fn_test8 ( _f : fn ( ) -> _ ) { }
100112 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
101113 //~| ERROR the type placeholder `_` is not allowed within types on item signatures
114+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
102115
103116 struct FnTest9 ;
104117
@@ -108,6 +121,7 @@ pub fn main() {
108121
109122 fn fn_test10 ( & self , _x : _ ) { }
110123 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
124+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
111125 }
112126
113127 impl Clone for FnTest9 {
@@ -116,12 +130,16 @@ pub fn main() {
116130
117131 fn clone_from ( & mut self , other : _ ) { * self = FnTest9 ; }
118132 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
133+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
119134 }
120135
121136 struct FnTest10 {
122137 a : _ ,
123138 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
139+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
124140 b : ( _ , _ ) ,
141+ //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
142+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
125143 }
126144
127145 fn fn_test11 ( _: _ ) -> ( _ , _ ) { panic ! ( ) }
@@ -138,28 +156,40 @@ pub fn main() {
138156trait T {
139157 fn method_test1 ( & self , x : _ ) ;
140158 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
159+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
141160 fn method_test2 ( & self , x : _ ) -> _ ;
142161 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
162+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
163+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
143164 fn method_test3 ( & self ) -> _ ;
144165 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
166+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
145167 fn assoc_fn_test1 ( x : _ ) ;
146168 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
169+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
147170 fn assoc_fn_test2 ( x : _ ) -> _ ;
148171 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
172+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
173+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
149174 fn assoc_fn_test3 ( ) -> _ ;
150175 //~^ ERROR the type placeholder `_` is not allowed within types on item signatures
176+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
151177}
152178
153179struct BadStruct < _ > ( _ ) ;
154180//~^ ERROR expected identifier, found reserved identifier `_`
155181//~| ERROR the type placeholder `_` is not allowed within types on item signatures
182+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
156183trait BadTrait < _ > { }
157184//~^ ERROR expected identifier, found reserved identifier `_`
158185impl BadTrait < _ > for BadStruct < _ > { }
159186//~^ ERROR the type placeholder `_` is not allowed within types on item signatures
187+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
188+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
160189
161190fn impl_trait ( ) -> impl BadTrait < _ > {
162191//~^ ERROR the type placeholder `_` is not allowed within types on item signatures
192+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
163193 unimplemented ! ( )
164194}
165195
@@ -168,18 +198,22 @@ struct BadStruct1<_, _>(_);
168198//~| ERROR expected identifier, found reserved identifier `_`
169199//~| ERROR the name `_` is already used
170200//~| ERROR the type placeholder `_` is not allowed within types on item signatures
201+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
171202struct BadStruct2 < _ , T > ( _ , T ) ;
172203//~^ ERROR expected identifier, found reserved identifier `_`
173204//~| ERROR the type placeholder `_` is not allowed within types on item signatures
205+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
174206
175207type X = Box < _ > ;
176208//~^ ERROR the type placeholder `_` is not allowed within types on item signatures
209+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
177210
178211struct Struct ;
179212trait Trait < T > { }
180213impl Trait < usize > for Struct { }
181214type Y = impl Trait < _ > ;
182215//~^ ERROR the type placeholder `_` is not allowed within types on item signatures
216+ //~| ERROR the type placeholder `_` is not allowed within types on item signatures
183217fn foo ( ) -> Y {
184218 Struct
185219}
0 commit comments