File tree 3 files changed +9
-9
lines changed
3 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -61,12 +61,12 @@ impl RegClass {
61
61
}
62
62
}
63
63
64
- trait ClassList {
64
+ trait ClassList for Sized ? {
65
65
fn is_pass_byval ( & self ) -> bool ;
66
66
fn is_ret_bysret ( & self ) -> bool ;
67
67
}
68
68
69
- impl < ' a > ClassList for & ' a [ RegClass ] {
69
+ impl ClassList for [ RegClass ] {
70
70
fn is_pass_byval ( & self ) -> bool {
71
71
if self . len ( ) == 0 { return false ; }
72
72
Original file line number Diff line number Diff line change @@ -12,11 +12,11 @@ use middle::trans::context::CrateContext;
12
12
use middle:: trans:: type_:: Type ;
13
13
use llvm:: ValueRef ;
14
14
15
- pub trait LlvmRepr {
15
+ pub trait LlvmRepr for Sized ? {
16
16
fn llrepr ( & self , ccx : & CrateContext ) -> String ;
17
17
}
18
18
19
- impl < ' a , T : LlvmRepr > LlvmRepr for & ' a [ T ] {
19
+ impl < T : LlvmRepr > LlvmRepr for [ T ] {
20
20
fn llrepr ( & self , ccx : & CrateContext ) -> String {
21
21
let reprs: Vec < String > = self . iter ( ) . map ( |t| t. llrepr ( ccx) ) . collect ( ) ;
22
22
format ! ( "[{}]" , reprs. connect( "," ) )
Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ use syntax::{ast, ast_util};
37
37
use syntax:: owned_slice:: OwnedSlice ;
38
38
39
39
/// Produces a string suitable for debugging output.
40
- pub trait Repr {
40
+ pub trait Repr for Sized ? {
41
41
fn repr ( & self , tcx : & ctxt ) -> String ;
42
42
}
43
43
@@ -578,9 +578,9 @@ impl Repr for () {
578
578
}
579
579
}
580
580
581
- impl < ' a , T : Repr > Repr for & ' a T {
581
+ impl < ' a , Sized ? T : Repr > Repr for & ' a T {
582
582
fn repr ( & self , tcx : & ctxt ) -> String {
583
- ( & * * self ) . repr ( tcx)
583
+ Repr :: repr ( * self , tcx)
584
584
}
585
585
}
586
586
@@ -600,9 +600,9 @@ fn repr_vec<T:Repr>(tcx: &ctxt, v: &[T]) -> String {
600
600
vec_map_to_string ( v, |t| t. repr ( tcx) )
601
601
}
602
602
603
- impl < ' a , T : Repr > Repr for & ' a [ T ] {
603
+ impl < T : Repr > Repr for [ T ] {
604
604
fn repr ( & self , tcx : & ctxt ) -> String {
605
- repr_vec ( tcx, * self )
605
+ repr_vec ( tcx, self )
606
606
}
607
607
}
608
608
You can’t perform that action at this time.
0 commit comments