@@ -252,6 +252,9 @@ step_impl_no_between!(u128 i128);
252
252
#[ derive( Clone , Debug ) ]
253
253
#[ unstable( feature = "step_by" , reason = "recent addition" ,
254
254
issue = "27741" ) ]
255
+ #[ rustc_deprecated( since = "1.19.0" ,
256
+ reason = "replaced by `iter::StepBy`" ) ]
257
+ #[ allow( deprecated) ]
255
258
pub struct StepBy < A , R > {
256
259
step_by : A ,
257
260
range : R ,
@@ -274,6 +277,7 @@ impl<A: Step> ops::RangeFrom<A> {
274
277
issue = "27741" ) ]
275
278
#[ rustc_deprecated( since = "1.19.0" ,
276
279
reason = "replaced by `Iterator::step_by`" ) ]
280
+ #[ allow( deprecated) ]
277
281
pub fn step_by ( self , by : A ) -> StepBy < A , Self > {
278
282
StepBy {
279
283
step_by : by,
@@ -301,6 +305,7 @@ impl<A: Step> ops::Range<A> {
301
305
issue = "27741" ) ]
302
306
#[ rustc_deprecated( since = "1.19.0" ,
303
307
reason = "replaced by `Iterator::step_by`" ) ]
308
+ #[ allow( deprecated) ]
304
309
pub fn step_by ( self , by : A ) -> StepBy < A , Self > {
305
310
StepBy {
306
311
step_by : by,
@@ -327,6 +332,7 @@ impl<A: Step> ops::RangeInclusive<A> {
327
332
issue = "27741" ) ]
328
333
#[ rustc_deprecated( since = "1.19.0" ,
329
334
reason = "replaced by `Iterator::step_by`" ) ]
335
+ #[ allow( deprecated) ]
330
336
pub fn step_by ( self , by : A ) -> StepBy < A , Self > {
331
337
StepBy {
332
338
step_by : by,
@@ -337,6 +343,7 @@ impl<A: Step> ops::RangeInclusive<A> {
337
343
338
344
#[ unstable( feature = "step_by" , reason = "recent addition" ,
339
345
issue = "27741" ) ]
346
+ #[ allow( deprecated) ]
340
347
impl < A > Iterator for StepBy < A , ops:: RangeFrom < A > > where
341
348
A : Clone ,
342
349
for < ' a > & ' a A : Add < & ' a A , Output = A >
@@ -357,11 +364,13 @@ impl<A> Iterator for StepBy<A, ops::RangeFrom<A>> where
357
364
}
358
365
359
366
#[ unstable( feature = "fused" , issue = "35602" ) ]
367
+ #[ allow( deprecated) ]
360
368
impl < A > FusedIterator for StepBy < A , ops:: RangeFrom < A > >
361
369
where A : Clone , for < ' a > & ' a A : Add < & ' a A , Output = A > { }
362
370
363
371
#[ unstable( feature = "step_by" , reason = "recent addition" ,
364
372
issue = "27741" ) ]
373
+ #[ allow( deprecated) ]
365
374
impl < A : Step + Clone > Iterator for StepBy < A , ops:: Range < A > > {
366
375
type Item = A ;
367
376
@@ -399,11 +408,13 @@ impl<A: Step + Clone> Iterator for StepBy<A, ops::Range<A>> {
399
408
}
400
409
401
410
#[ unstable( feature = "fused" , issue = "35602" ) ]
411
+ #[ allow( deprecated) ]
402
412
impl < A : Step + Clone > FusedIterator for StepBy < A , ops:: Range < A > > { }
403
413
404
414
#[ unstable( feature = "inclusive_range" ,
405
415
reason = "recently added, follows RFC" ,
406
416
issue = "28237" ) ]
417
+ #[ allow( deprecated) ]
407
418
impl < A : Step + Clone > Iterator for StepBy < A , ops:: RangeInclusive < A > > {
408
419
type Item = A ;
409
420
@@ -443,6 +454,7 @@ impl<A: Step + Clone> Iterator for StepBy<A, ops::RangeInclusive<A>> {
443
454
}
444
455
445
456
#[ unstable( feature = "fused" , issue = "35602" ) ]
457
+ #[ allow( deprecated) ]
446
458
impl < A : Step + Clone > FusedIterator for StepBy < A , ops:: RangeInclusive < A > > { }
447
459
448
460
macro_rules! range_exact_iter_impl {
0 commit comments