File tree 1 file changed +8
-2
lines changed
1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -1498,7 +1498,10 @@ impl<T: Clone> Option<&T> {
1498
1498
#[ must_use = "`self` will be dropped if the result is not used" ]
1499
1499
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
1500
1500
#[ rustc_const_unstable( feature = "const_option_cloned" , issue = "none" ) ]
1501
- pub const fn cloned ( self ) -> Option < T > where T : ~const Clone {
1501
+ pub const fn cloned ( self ) -> Option < T >
1502
+ where
1503
+ T : ~const Clone ,
1504
+ {
1502
1505
match self {
1503
1506
Some ( t) => Some ( t. clone ( ) ) ,
1504
1507
None => None ,
@@ -1522,7 +1525,10 @@ impl<T: Clone> Option<&mut T> {
1522
1525
#[ must_use = "`self` will be dropped if the result is not used" ]
1523
1526
#[ stable( since = "1.26.0" , feature = "option_ref_mut_cloned" ) ]
1524
1527
#[ rustc_const_unstable( feature = "const_option_cloned" , issue = "none" ) ]
1525
- pub const fn cloned ( self ) -> Option < T > where T : ~const Clone {
1528
+ pub const fn cloned ( self ) -> Option < T >
1529
+ where
1530
+ T : ~const Clone ,
1531
+ {
1526
1532
match self {
1527
1533
Some ( t) => Some ( t. clone ( ) ) ,
1528
1534
None => None ,
You can’t perform that action at this time.
0 commit comments