@@ -42,7 +42,6 @@ use syntax::abi::Abi;
42
42
use syntax:: ast:: { Name , NodeId , DUMMY_NODE_ID , TokenTree , AsmDialect } ;
43
43
use syntax:: ast:: { Attribute , Lit , StrStyle , FloatTy , IntTy , UintTy , CrateConfig } ;
44
44
use syntax:: attr:: ThinAttributes ;
45
- use syntax:: owned_slice:: OwnedSlice ;
46
45
use syntax:: parse:: token:: InternedString ;
47
46
use syntax:: ptr:: P ;
48
47
@@ -193,8 +192,8 @@ impl PathParameters {
193
192
pub fn none ( ) -> PathParameters {
194
193
AngleBracketedParameters ( AngleBracketedParameterData {
195
194
lifetimes : Vec :: new ( ) ,
196
- types : OwnedSlice :: empty ( ) ,
197
- bindings : OwnedSlice :: empty ( ) ,
195
+ types : P :: empty ( ) ,
196
+ bindings : P :: empty ( ) ,
198
197
} )
199
198
}
200
199
@@ -267,10 +266,10 @@ pub struct AngleBracketedParameterData {
267
266
/// The lifetime parameters for this path segment.
268
267
pub lifetimes : Vec < Lifetime > ,
269
268
/// The type parameters for this path segment, if present.
270
- pub types : OwnedSlice < P < Ty > > ,
269
+ pub types : P < [ P < Ty > ] > ,
271
270
/// Bindings (equality constraints) on associated types, if present.
272
271
/// E.g., `Foo<A=Bar>`.
273
- pub bindings : OwnedSlice < TypeBinding > ,
272
+ pub bindings : P < [ TypeBinding ] > ,
274
273
}
275
274
276
275
impl AngleBracketedParameterData {
@@ -310,7 +309,7 @@ pub enum TraitBoundModifier {
310
309
Maybe ,
311
310
}
312
311
313
- pub type TyParamBounds = OwnedSlice < TyParamBound > ;
312
+ pub type TyParamBounds = P < [ TyParamBound ] > ;
314
313
315
314
#[ derive( Clone , PartialEq , Eq , RustcEncodable , RustcDecodable , Hash , Debug ) ]
316
315
pub struct TyParam {
@@ -326,7 +325,7 @@ pub struct TyParam {
326
325
#[ derive( Clone , PartialEq , Eq , RustcEncodable , RustcDecodable , Hash , Debug ) ]
327
326
pub struct Generics {
328
327
pub lifetimes : Vec < LifetimeDef > ,
329
- pub ty_params : OwnedSlice < TyParam > ,
328
+ pub ty_params : P < [ TyParam ] > ,
330
329
pub where_clause : WhereClause ,
331
330
}
332
331
@@ -369,7 +368,7 @@ pub struct WhereBoundPredicate {
369
368
/// The type being bounded
370
369
pub bounded_ty : P < Ty > ,
371
370
/// Trait and lifetime bounds (`Clone+Send+'static`)
372
- pub bounds : OwnedSlice < TyParamBound > ,
371
+ pub bounds : TyParamBounds ,
373
372
}
374
373
375
374
/// A lifetime predicate, e.g. `'a: 'b+'c`
0 commit comments