diff options
| author | Michael Sullivan <sully@msully.net> | 2012-07-12 10:28:43 -0700 |
|---|---|---|
| committer | Michael Sullivan <sully@msully.net> | 2012-07-12 15:03:54 -0700 |
| commit | 9d2e5f3a6507ab14e18669bdeed973f6bc9935ff (patch) | |
| tree | 8a94698d06f6305550c7fe164b3a148f8a3ca940 /src/libsyntax/ext | |
| parent | b9aa9def858cfc66d411972b10ce3d98479acd78 (diff) | |
| parent | a8db1bd4ef3d2464b3a13c049491f25e6a4aaa32 (diff) | |
| download | rust-9d2e5f3a6507ab14e18669bdeed973f6bc9935ff.tar.gz rust-9d2e5f3a6507ab14e18669bdeed973f6bc9935ff.zip | |
Merge branch 'rt-changes' into incoming
Diffstat (limited to 'src/libsyntax/ext')
| -rw-r--r-- | src/libsyntax/ext/auto_serialize.rs | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/libsyntax/ext/auto_serialize.rs b/src/libsyntax/ext/auto_serialize.rs index 6bbce757a92..0de49367b17 100644 --- a/src/libsyntax/ext/auto_serialize.rs +++ b/src/libsyntax/ext/auto_serialize.rs @@ -459,7 +459,6 @@ fn ser_ty(cx: ext_ctxt, tps: ser_tps_map, ~[] } - ast::ty_vstore(@{node: ast::ty_vec(mt),_}, ast::vstore_uniq) | ast::ty_vec(mt) { let ser_e = cx.expr( @@ -477,6 +476,11 @@ fn ser_ty(cx: ext_ctxt, tps: ser_tps_map, }] } + // For unique vstores, just pass through to the underlying vec or str + ast::ty_vstore(ty, ast::vstore_uniq) { + ser_ty(cx, tps, ty, s, v) + } + ast::ty_vstore(_, _) { cx.span_unimpl(ty.span, "serialization for vstore types"); } @@ -685,12 +689,16 @@ fn deser_ty(cx: ext_ctxt, tps: deser_tps_map, #ast{ fail } } - ast::ty_vstore(@{node: ast::ty_vec(mt),_}, ast::vstore_uniq) | ast::ty_vec(mt) { let l = deser_lambda(cx, tps, mt.ty, cx.clone(d)); #ast{ std::serialization::read_to_vec($(d), $(l)) } } + // For unique vstores, just pass through to the underlying vec or str + ast::ty_vstore(ty, ast::vstore_uniq) { + deser_ty(cx, tps, ty, d) + } + ast::ty_vstore(_, _) { cx.span_unimpl(ty.span, "deserialization for vstore types"); } |
