From f30f54e9d062bdb5b3cb10dd7185470280c1c278 Mon Sep 17 00:00:00 2001 From: Patrick Walton Date: Wed, 24 Apr 2013 01:29:46 -0700 Subject: librustc: Remove the concept of modes from the compiler. This commit does not remove `ty::arg`, although that should be possible to do now. --- src/libsyntax/ext/auto_encode.rs | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) (limited to 'src/libsyntax/ext/auto_encode.rs') diff --git a/src/libsyntax/ext/auto_encode.rs b/src/libsyntax/ext/auto_encode.rs index 0d451c66edb..da7b9570131 100644 --- a/src/libsyntax/ext/auto_encode.rs +++ b/src/libsyntax/ext/auto_encode.rs @@ -608,7 +608,6 @@ fn mk_ser_method( }; let ser_inputs = ~[ast::arg { - mode: ast::infer(cx.next_id()), is_mutbl: false, ty: ty_s, pat: @ast::pat { @@ -670,20 +669,22 @@ fn mk_deser_method( span: span, }; - let deser_inputs = ~[ast::arg { - mode: ast::infer(cx.next_id()), - is_mutbl: false, - ty: ty_d, - pat: @ast::pat { + let deser_inputs = ~[ + ast::arg { + is_mutbl: false, + ty: ty_d, + pat: @ast::pat { + id: cx.next_id(), + node: ast::pat_ident(ast::bind_by_copy, + ast_util::ident_to_path(span, + cx.ident_of( + ~"__d")), + None), + span: span, + }, id: cx.next_id(), - node: ast::pat_ident( - ast::bind_by_copy, - ast_util::ident_to_path(span, cx.ident_of(~"__d")), - None), - span: span, - }, - id: cx.next_id(), - }]; + } + ]; let deser_decl = ast::fn_decl { inputs: deser_inputs, @@ -1120,7 +1121,6 @@ fn mk_enum_deser_body( ast::expr_fn_block( ast::fn_decl { inputs: ~[ast::arg { - mode: ast::infer(ext_cx.next_id()), is_mutbl: false, ty: @ast::Ty { id: ext_cx.next_id(), -- cgit 1.4.1-3-g733a5