Skip to content

Commit

Permalink
fix "warning: deprecated syntax, use for keyword now"
Browse files Browse the repository at this point in the history
  • Loading branch information
Jorge Aparicio committed Nov 13, 2014
1 parent f6c0250 commit e5ef556
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 12 deletions.
12 changes: 6 additions & 6 deletions src/librustc/metadata/decoder.rs
Expand Up @@ -630,12 +630,12 @@ pub fn get_item_path(cdata: Cmd, id: ast::NodeId) -> Vec<ast_map::PathElem> {
item_path(lookup_item(id, cdata.data()))
}

pub type DecodeInlinedItem<'a> = <'tcx> |cdata: Cmd,
tcx: &ty::ctxt<'tcx>,
path: Vec<ast_map::PathElem>,
par_doc: rbml::Doc|: 'a
-> Result<&'tcx ast::InlinedItem,
Vec<ast_map::PathElem>>;
pub type DecodeInlinedItem<'a> = for<'tcx> |cdata: Cmd,
tcx: &ty::ctxt<'tcx>,
path: Vec<ast_map::PathElem>,
par_doc: rbml::Doc|: 'a
-> Result<&'tcx ast::InlinedItem,
Vec<ast_map::PathElem>>;

pub fn maybe_get_item_ast<'tcx>(cdata: Cmd, tcx: &ty::ctxt<'tcx>, id: ast::NodeId,
decode_inlined_item: DecodeInlinedItem)
Expand Down
4 changes: 2 additions & 2 deletions src/librustc/middle/trans/base.rs
Expand Up @@ -1787,8 +1787,8 @@ pub fn trans_closure(ccx: &CrateContext,
abi: Abi,
has_env: bool,
is_unboxed_closure: IsUnboxedClosureFlag,
maybe_load_env: <'blk, 'tcx> |Block<'blk, 'tcx>, ScopeId|
-> Block<'blk, 'tcx>) {
maybe_load_env: for<'blk, 'tcx> |Block<'blk, 'tcx>, ScopeId|
-> Block<'blk, 'tcx>) {
ccx.stats().n_closures.set(ccx.stats().n_closures.get() + 1);

let _icx = push_ctxt("trans_closure");
Expand Down
4 changes: 2 additions & 2 deletions src/librustc/middle/trans/glue.rs
Expand Up @@ -528,8 +528,8 @@ fn declare_generic_glue(ccx: &CrateContext, t: ty::t, llfnty: Type,
fn make_generic_glue(ccx: &CrateContext,
t: ty::t,
llfn: ValueRef,
helper: <'blk, 'tcx> |Block<'blk, 'tcx>, ValueRef, ty::t|
-> Block<'blk, 'tcx>,
helper: for<'blk, 'tcx> |Block<'blk, 'tcx>, ValueRef, ty::t|
-> Block<'blk, 'tcx>,
name: &str)
-> ValueRef {
let _icx = push_ctxt("make_generic_glue");
Expand Down
4 changes: 2 additions & 2 deletions src/libsyntax/ext/base.rs
Expand Up @@ -89,7 +89,7 @@ pub trait TTMacroExpander {
}

pub type MacroExpanderFn =
fn<'cx>(&'cx mut ExtCtxt, Span, &[ast::TokenTree]) -> Box<MacResult+'cx>;
for<'cx> fn(&'cx mut ExtCtxt, Span, &[ast::TokenTree]) -> Box<MacResult+'cx>;

impl TTMacroExpander for MacroExpanderFn {
fn expand<'cx>(&self,
Expand All @@ -111,7 +111,7 @@ pub trait IdentMacroExpander {
}

pub type IdentMacroExpanderFn =
fn<'cx>(&'cx mut ExtCtxt, Span, ast::Ident, Vec<ast::TokenTree>) -> Box<MacResult+'cx>;
for<'cx> fn(&'cx mut ExtCtxt, Span, ast::Ident, Vec<ast::TokenTree>) -> Box<MacResult+'cx>;

impl IdentMacroExpander for IdentMacroExpanderFn {
fn expand<'cx>(&self,
Expand Down

5 comments on commit e5ef556

@bors
Copy link
Contributor

@bors bors commented on e5ef556 Nov 15, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

saw approval from jakub-
at japaric@e5ef556

@bors
Copy link
Contributor

@bors bors commented on e5ef556 Nov 15, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

merging japaric/rust/for = e5ef556 into auto

@bors
Copy link
Contributor

@bors bors commented on e5ef556 Nov 15, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

japaric/rust/for = e5ef556 merged ok, testing candidate = d3af16b

@bors
Copy link
Contributor

@bors bors commented on e5ef556 Nov 15, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bors
Copy link
Contributor

@bors bors commented on e5ef556 Nov 15, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fast-forwarding master to auto = d3af16b

Please sign in to comment.