File tree Expand file tree Collapse file tree 5 files changed +641
-662
lines changed Expand file tree Collapse file tree 5 files changed +641
-662
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ refs/heads/try3: 9387340aab40a73e8424c48fd42f0c521a4875c0
13
13
refs/tags/release-0.3.1: 495bae036dfe5ec6ceafd3312b4dca48741e845b
14
14
refs/tags/release-0.4: e828ea2080499553b97dfe33b3f4d472b4562ad7
15
15
refs/tags/release-0.5: 7e3bcfbf21278251ee936ad53e92e9b719702d73
16
- refs/heads/auto: 1562d8cbd890d39640d98afa59424cc8002ea85a
16
+ refs/heads/auto: dad2db7c83de71063b9311eb3e41bdf4027616f6
17
17
refs/heads/servo: af82457af293e2a842ba6b7759b70288da276167
18
18
refs/tags/release-0.6: b4ebcfa1812664df5e142f0134a5faea3918544c
19
19
refs/tags/0.1: b19db808c2793fe2976759b85a355c3ad8c8b336
Original file line number Diff line number Diff line change @@ -120,6 +120,13 @@ impl ImplOrTraitItem {
120
120
TypeTraitItem ( ref associated_type) => associated_type. container ,
121
121
}
122
122
}
123
+
124
+ pub fn as_opt_method ( & self ) -> Option < Rc < Method > > {
125
+ match * self {
126
+ MethodTraitItem ( ref m) => Some ( ( * m) . clone ( ) ) ,
127
+ TypeTraitItem ( _) => None
128
+ }
129
+ }
123
130
}
124
131
125
132
#[ deriving( Clone ) ]
@@ -1240,6 +1247,10 @@ impl Generics {
1240
1247
}
1241
1248
1242
1249
impl TraitRef {
1250
+ pub fn new ( def_id : ast:: DefId , substs : Substs ) -> TraitRef {
1251
+ TraitRef { def_id : def_id, substs : substs }
1252
+ }
1253
+
1243
1254
pub fn self_ty ( & self ) -> ty:: t {
1244
1255
self . substs . self_ty ( ) . unwrap ( )
1245
1256
}
You can’t perform that action at this time.
0 commit comments