about summary refs log tree commit diff
path: root/src/libsyntax/ext/deriving
diff options
context:
space:
mode:
authorEduard Burtescu <edy.burt@gmail.com>2014-02-07 00:38:33 +0200
committerEduard Burtescu <edy.burt@gmail.com>2014-02-07 00:38:33 +0200
commitb2d30b72bfaa1f36808151e5825073cdff2e7ea7 (patch)
tree14ff6b505eeee456236727940e5804e3e812b1b5 /src/libsyntax/ext/deriving
parentc13a929d58c3f866687ccf12cc33b2b59a2e10b8 (diff)
downloadrust-b2d30b72bfaa1f36808151e5825073cdff2e7ea7.tar.gz
rust-b2d30b72bfaa1f36808151e5825073cdff2e7ea7.zip
Removed @self and @Trait.
Diffstat (limited to 'src/libsyntax/ext/deriving')
-rw-r--r--src/libsyntax/ext/deriving/encodable.rs4
-rw-r--r--src/libsyntax/ext/deriving/ty.rs5
2 files changed, 2 insertions, 7 deletions
diff --git a/src/libsyntax/ext/deriving/encodable.rs b/src/libsyntax/ext/deriving/encodable.rs
index 66b744ecbcb..a44e4af5b6b 100644
--- a/src/libsyntax/ext/deriving/encodable.rs
+++ b/src/libsyntax/ext/deriving/encodable.rs
@@ -75,7 +75,7 @@ would yield functions like:
     }
 */
 
-use ast::{MetaItem, Item, Expr, MutImmutable, MutMutable};
+use ast::{MetaItem, Item, Expr, MutMutable};
 use codemap::Span;
 use ext::base::ExtCtxt;
 use ext::build::AstBuilder;
@@ -100,7 +100,7 @@ pub fn expand_deriving_encodable(cx: &ExtCtxt,
             MethodDef {
                 name: "encode",
                 generics: LifetimeBounds::empty(),
-                explicit_self: Some(Some(Borrowed(None, MutImmutable))),
+                explicit_self: borrowed_explicit_self(),
                 args: ~[Ptr(~Literal(Path::new_local("__E")),
                             Borrowed(None, MutMutable))],
                 ret_ty: nil_ty(),
diff --git a/src/libsyntax/ext/deriving/ty.rs b/src/libsyntax/ext/deriving/ty.rs
index 893a1c68426..f37abbe1ef4 100644
--- a/src/libsyntax/ext/deriving/ty.rs
+++ b/src/libsyntax/ext/deriving/ty.rs
@@ -24,7 +24,6 @@ use opt_vec::OptVec;
 /// The types of pointers
 pub enum PtrTy<'a> {
     Send, // ~
-    Managed, // @
     Borrowed(Option<&'a str>, ast::Mutability), // &['lifetime] [mut]
 }
 
@@ -138,9 +137,6 @@ impl<'a> Ty<'a> {
                     Send => {
                         cx.ty_uniq(span, raw_ty)
                     }
-                    Managed => {
-                        cx.ty_box(span, raw_ty)
-                    }
                     Borrowed(ref lt, mutbl) => {
                         let lt = mk_lifetime(cx, span, lt);
                         cx.ty_rptr(span, raw_ty, lt, mutbl)
@@ -251,7 +247,6 @@ pub fn get_explicit_self(cx: &ExtCtxt, span: Span, self_ptr: &Option<PtrTy>)
                 span,
                 match *ptr {
                     Send => ast::SelfUniq,
-                    Managed => ast::SelfBox,
                     Borrowed(ref lt, mutbl) => {
                         let lt = lt.map(|s| cx.lifetime(span, cx.ident_of(s)));
                         ast::SelfRegion(lt, mutbl)