11// See core/src/primitive_docs.rs for documentation.
22
33use crate :: cmp:: Ordering :: { self , * } ;
4- use crate :: marker:: { ConstParamTy_ , PointeeSized , StructuralPartialEq , UnsizedConstParamTy } ;
4+ use crate :: marker:: { ConstParamTy_ , StructuralPartialEq , UnsizedConstParamTy } ;
55use crate :: ops:: ControlFlow :: { self , Break , Continue } ;
66use crate :: random:: { Random , RandomSource } ;
77
@@ -24,10 +24,7 @@ macro_rules! tuple_impls {
2424 maybe_tuple_doc! {
2525 $( $T) + @
2626 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
27- impl <$( $T: PartialEq ) ,+> PartialEq for ( $( $T, ) +)
28- where
29- last_type!( $( $T, ) +) : PointeeSized
30- {
27+ impl <$( $T: PartialEq ) ,+> PartialEq for ( $( $T, ) +) {
3128 #[ inline]
3229 fn eq( & self , other: & ( $( $T, ) +) ) -> bool {
3330 $( ${ ignore( $T) } self . ${ index( ) } == other. ${ index( ) } ) &&+
@@ -43,8 +40,6 @@ macro_rules! tuple_impls {
4340 $( $T) + @
4441 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
4542 impl <$( $T: Eq ) ,+> Eq for ( $( $T, ) +)
46- where
47- last_type!( $( $T, ) +) : PointeeSized
4843 { }
4944 }
5045
@@ -73,8 +68,6 @@ macro_rules! tuple_impls {
7368 $( $T) + @
7469 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
7570 impl <$( $T: PartialOrd ) ,+> PartialOrd for ( $( $T, ) +)
76- where
77- last_type!( $( $T, ) +) : PointeeSized
7871 {
7972 #[ inline]
8073 fn partial_cmp( & self , other: & ( $( $T, ) +) ) -> Option <Ordering > {
@@ -119,8 +112,6 @@ macro_rules! tuple_impls {
119112 $( $T) + @
120113 #[ stable( feature = "rust1" , since = "1.0.0" ) ]
121114 impl <$( $T: Ord ) ,+> Ord for ( $( $T, ) +)
122- where
123- last_type!( $( $T, ) +) : PointeeSized
124115 {
125116 #[ inline]
126117 fn cmp( & self , other: & ( $( $T, ) +) ) -> Ordering {
@@ -245,9 +236,4 @@ macro_rules! lexical_cmp {
245236 ( $a: expr, $b: expr) => { ( $a) . cmp( & $b) } ;
246237}
247238
248- macro_rules! last_type {
249- ( $a: ident, ) => { $a } ;
250- ( $a: ident, $( $rest_a: ident, ) +) => { last_type!( $( $rest_a, ) +) } ;
251- }
252-
253239tuple_impls ! ( E D C B A Z Y X W V U T ) ;
0 commit comments