diff options
| author | Patrick Walton <[email protected]> | 2011-03-31 19:12:40 -0700 |
|---|---|---|
| committer | Patrick Walton <[email protected]> | 2011-03-31 19:12:40 -0700 |
| commit | c66edca83d04c5be5c27629b43c2c180a67f2d63 (patch) | |
| tree | 37db28b65567fd8c067c82d1917878181a69c0f5 /src/comp/middle/metadata.rs | |
| parent | rustc: Make tag_ty_params() and substitute_ty_params() take def ids instead o... (diff) | |
| download | rust-c66edca83d04c5be5c27629b43c2c180a67f2d63.tar.xz rust-c66edca83d04c5be5c27629b43c2c180a67f2d63.zip | |
rustc: Add a type annotation to tag items
Diffstat (limited to 'src/comp/middle/metadata.rs')
| -rw-r--r-- | src/comp/middle/metadata.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/comp/middle/metadata.rs b/src/comp/middle/metadata.rs index 6a470e39..c42ed6db 100644 --- a/src/comp/middle/metadata.rs +++ b/src/comp/middle/metadata.rs @@ -262,7 +262,7 @@ fn encode_module_item_paths(&ebml.writer ebml_w, encode_def_id(ebml_w, did); ebml.end_tag(ebml_w); } - case (ast.item_tag(?id, ?variants, ?tps, ?did)) { + case (ast.item_tag(?id, ?variants, ?tps, ?did, _)) { add_to_index(ebml_w, path, index, id); ebml.start_tag(ebml_w, tag_paths_data_item); encode_name(ebml_w, id); @@ -403,11 +403,12 @@ fn encode_info_for_item(@trans.crate_ctxt cx, &ebml.writer ebml_w, encode_type(ebml_w, trans.node_ann_type(cx, ann)); ebml.end_tag(ebml_w); } - case (ast.item_tag(?id, ?variants, ?tps, ?did)) { + case (ast.item_tag(?id, ?variants, ?tps, ?did, ?ann)) { ebml.start_tag(ebml_w, tag_items_data_item); encode_def_id(ebml_w, did); encode_kind(ebml_w, 't' as u8); encode_type_params(ebml_w, tps); + encode_type(ebml_w, trans.node_ann_type(cx, ann)); ebml.end_tag(ebml_w); encode_tag_variant_info(cx, ebml_w, did, variants); |