File tree Expand file tree Collapse file tree 2 files changed +4
-9
lines changed Expand file tree Collapse file tree 2 files changed +4
-9
lines changed Original file line number Diff line number Diff line change @@ -1481,14 +1481,11 @@ pub trait PartialOrd<Rhs: PointeeSized = Self>: PartialEq<Rhs> + PointeeSized {
1481
1481
}
1482
1482
}
1483
1483
1484
- fn default_chaining_impl < T : PointeeSized , U : PointeeSized > (
1484
+ fn default_chaining_impl < T : PartialOrd < U > + PointeeSized , U : PointeeSized > (
1485
1485
lhs : & T ,
1486
1486
rhs : & U ,
1487
1487
p : impl FnOnce ( Ordering ) -> bool ,
1488
- ) -> ControlFlow < bool >
1489
- where
1490
- T : PartialOrd < U > ,
1491
- {
1488
+ ) -> ControlFlow < bool > {
1492
1489
// It's important that this only call `partial_cmp` once, not call `eq` then
1493
1490
// one of the relational operators. We don't want to `bcmp`-then-`memcp` a
1494
1491
// `String`, for example, or similarly for other data structures (#108157).
Original file line number Diff line number Diff line change @@ -3414,10 +3414,9 @@ pub trait Iterator {
3414
3414
/// ```
3415
3415
#[ stable( feature = "iter_copied" , since = "1.36.0" ) ]
3416
3416
#[ rustc_diagnostic_item = "iter_copied" ]
3417
- fn copied < ' a , T : ' a > ( self ) -> Copied < Self >
3417
+ fn copied < ' a , T : Copy + ' a > ( self ) -> Copied < Self >
3418
3418
where
3419
3419
Self : Sized + Iterator < Item = & ' a T > ,
3420
- T : Copy ,
3421
3420
{
3422
3421
Copied :: new ( self )
3423
3422
}
@@ -3462,10 +3461,9 @@ pub trait Iterator {
3462
3461
/// ```
3463
3462
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
3464
3463
#[ rustc_diagnostic_item = "iter_cloned" ]
3465
- fn cloned < ' a , T : ' a > ( self ) -> Cloned < Self >
3464
+ fn cloned < ' a , T : Clone + ' a > ( self ) -> Cloned < Self >
3466
3465
where
3467
3466
Self : Sized + Iterator < Item = & ' a T > ,
3468
- T : Clone ,
3469
3467
{
3470
3468
Cloned :: new ( self )
3471
3469
}
You can’t perform that action at this time.
0 commit comments