Skip to content

Commit d8ef723

Browse files
committed
rustc: Replace Durable with 'static
1 parent ccc4c1a commit d8ef723

File tree

3 files changed

+17
-17
lines changed

3 files changed

+17
-17
lines changed

src/librustc/middle/typeck/astconv.rs

+14-14
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ pub fn get_region_reporting_err(
101101
}
102102
}
103103

104-
pub fn ast_region_to_region<AC:AstConv,RS:region_scope + Copy + Durable>(
104+
pub fn ast_region_to_region<AC:AstConv,RS:region_scope + Copy + 'static>(
105105
self: &AC,
106106
rscope: &RS,
107107
default_span: span,
@@ -126,7 +126,7 @@ pub fn ast_region_to_region<AC:AstConv,RS:region_scope + Copy + Durable>(
126126
get_region_reporting_err(self.tcx(), span, opt_lifetime, res)
127127
}
128128

129-
fn ast_path_substs<AC:AstConv,RS:region_scope + Copy + Durable>(
129+
fn ast_path_substs<AC:AstConv,RS:region_scope + Copy + 'static>(
130130
self: &AC,
131131
rscope: &RS,
132132
def_id: ast::def_id,
@@ -180,7 +180,7 @@ fn ast_path_substs<AC:AstConv,RS:region_scope + Copy + Durable>(
180180
substs {self_r:self_r, self_ty:self_ty, tps:tps}
181181
}
182182

183-
pub fn ast_path_to_substs_and_ty<AC:AstConv,RS:region_scope + Copy + Durable>(
183+
pub fn ast_path_to_substs_and_ty<AC:AstConv,RS:region_scope + Copy + 'static>(
184184
self: &AC,
185185
rscope: &RS,
186186
did: ast::def_id,
@@ -197,7 +197,7 @@ pub fn ast_path_to_substs_and_ty<AC:AstConv,RS:region_scope + Copy + Durable>(
197197
ty_param_substs_and_ty { substs: substs, ty: ty }
198198
}
199199

200-
pub fn ast_path_to_trait_ref<AC:AstConv,RS:region_scope + Copy + Durable>(
200+
pub fn ast_path_to_trait_ref<AC:AstConv,RS:region_scope + Copy + 'static>(
201201
self: &AC,
202202
rscope: &RS,
203203
trait_def_id: ast::def_id,
@@ -221,7 +221,7 @@ pub fn ast_path_to_trait_ref<AC:AstConv,RS:region_scope + Copy + Durable>(
221221
}
222222

223223

224-
pub fn ast_path_to_ty<AC:AstConv,RS:region_scope + Copy + Durable>(
224+
pub fn ast_path_to_ty<AC:AstConv,RS:region_scope + Copy + 'static>(
225225
self: &AC,
226226
rscope: &RS,
227227
did: ast::def_id,
@@ -243,10 +243,10 @@ pub static NO_TPS: uint = 2;
243243
// Parses the programmer's textual representation of a type into our
244244
// internal notion of a type. `getter` is a function that returns the type
245245
// corresponding to a definition ID:
246-
pub fn ast_ty_to_ty<AC:AstConv, RS:region_scope + Copy + Durable>(
246+
pub fn ast_ty_to_ty<AC:AstConv, RS:region_scope + Copy + 'static>(
247247
self: &AC, rscope: &RS, ast_ty: @ast::Ty) -> ty::t {
248248

249-
fn ast_mt_to_mt<AC:AstConv, RS:region_scope + Copy + Durable>(
249+
fn ast_mt_to_mt<AC:AstConv, RS:region_scope + Copy + 'static>(
250250
self: &AC, rscope: &RS, mt: &ast::mt) -> ty::mt {
251251

252252
ty::mt {ty: ast_ty_to_ty(self, rscope, mt.ty), mutbl: mt.mutbl}
@@ -255,7 +255,7 @@ pub fn ast_ty_to_ty<AC:AstConv, RS:region_scope + Copy + Durable>(
255255
// Handle @, ~, and & being able to mean estrs and evecs.
256256
// If a_seq_ty is a str or a vec, make it an estr/evec.
257257
// Also handle first-class trait types.
258-
fn mk_pointer<AC:AstConv,RS:region_scope + Copy + Durable>(
258+
fn mk_pointer<AC:AstConv,RS:region_scope + Copy + 'static>(
259259
self: &AC,
260260
rscope: &RS,
261261
a_seq_ty: &ast::mt,
@@ -497,7 +497,7 @@ pub fn ast_ty_to_ty<AC:AstConv, RS:region_scope + Copy + Durable>(
497497
}
498498

499499
pub fn ty_of_arg<AC:AstConv,
500-
RS:region_scope + Copy + Durable>(
500+
RS:region_scope + Copy + 'static>(
501501
self: &AC,
502502
rscope: &RS,
503503
a: ast::arg,
@@ -549,7 +549,7 @@ struct SelfInfo {
549549
self_transform: ast::self_ty
550550
}
551551

552-
pub fn ty_of_method<AC:AstConv,RS:region_scope + Copy + Durable>(
552+
pub fn ty_of_method<AC:AstConv,RS:region_scope + Copy + 'static>(
553553
self: &AC,
554554
rscope: &RS,
555555
purity: ast::purity,
@@ -567,7 +567,7 @@ pub fn ty_of_method<AC:AstConv,RS:region_scope + Copy + Durable>(
567567
(a.get(), b)
568568
}
569569

570-
pub fn ty_of_bare_fn<AC:AstConv,RS:region_scope + Copy + Durable>(
570+
pub fn ty_of_bare_fn<AC:AstConv,RS:region_scope + Copy + 'static>(
571571
self: &AC,
572572
rscope: &RS,
573573
purity: ast::purity,
@@ -580,7 +580,7 @@ pub fn ty_of_bare_fn<AC:AstConv,RS:region_scope + Copy + Durable>(
580580
b
581581
}
582582

583-
fn ty_of_method_or_bare_fn<AC:AstConv,RS:region_scope + Copy + Durable>(
583+
fn ty_of_method_or_bare_fn<AC:AstConv,RS:region_scope + Copy + 'static>(
584584
self: &AC,
585585
rscope: &RS,
586586
purity: ast::purity,
@@ -616,7 +616,7 @@ fn ty_of_method_or_bare_fn<AC:AstConv,RS:region_scope + Copy + Durable>(
616616
output: output_ty}
617617
});
618618

619-
fn transform_self_ty<AC:AstConv,RS:region_scope + Copy + Durable>(
619+
fn transform_self_ty<AC:AstConv,RS:region_scope + Copy + 'static>(
620620
self: &AC,
621621
rscope: &RS,
622622
self_info: &SelfInfo) -> Option<ty::t>
@@ -649,7 +649,7 @@ fn ty_of_method_or_bare_fn<AC:AstConv,RS:region_scope + Copy + Durable>(
649649
}
650650
}
651651

652-
pub fn ty_of_closure<AC:AstConv,RS:region_scope + Copy + Durable>(
652+
pub fn ty_of_closure<AC:AstConv,RS:region_scope + Copy + 'static>(
653653
self: &AC,
654654
rscope: &RS,
655655
sigil: ast::Sigil,

src/librustc/middle/typeck/collect.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ pub fn collect_item_types(ccx: @mut CrateCtxt, crate: @ast::crate) {
116116
}
117117

118118
impl CrateCtxt {
119-
fn to_ty<RS:region_scope + Copy + Durable>(
119+
fn to_ty<RS:region_scope + Copy + 'static>(
120120
&self, rs: &RS, ast_ty: @ast::Ty) -> ty::t
121121
{
122122
ast_ty_to_ty(self, rs, ast_ty)
@@ -1163,7 +1163,7 @@ pub fn ty_generics(ccx: &CrateCtxt,
11631163
* enum consisting of a newtyped Ty or a region) to ty's
11641164
* notion of ty param bounds, which can either be user-defined
11651165
* traits, or one of the four built-in traits (formerly known
1166-
* as kinds): Const, Copy, Durable, and Send.
1166+
* as kinds): Const, Copy, and Send.
11671167
*/
11681168

11691169
@ast_bounds.flat_map_to_vec(|b| {

src/librustc/middle/typeck/rscope.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ pub struct binding_rscope {
266266
region_param_names: RegionParamNames,
267267
}
268268

269-
pub fn in_binding_rscope<RS:region_scope + Copy + Durable>(
269+
pub fn in_binding_rscope<RS:region_scope + Copy + 'static>(
270270
self: &RS,
271271
region_param_names: RegionParamNames)
272272
-> binding_rscope {

0 commit comments

Comments
 (0)