diff options
| author | Marijn Haverbeke <marijnh@gmail.com> | 2012-01-02 12:09:26 +0100 |
|---|---|---|
| committer | Marijn Haverbeke <marijnh@gmail.com> | 2012-01-02 15:15:27 +0100 |
| commit | 9f2369dc9f55a22cfc0bc8b62a8588afe2c8b2ca (patch) | |
| tree | 770413f0ec4d4279742ffaac21d3db40c9f7c9b0 /src/comp/metadata/decoder.rs | |
| parent | 270b4273e79aac33f424673caf455f839da2bb40 (diff) | |
| download | rust-9f2369dc9f55a22cfc0bc8b62a8588afe2c8b2ca.tar.gz rust-9f2369dc9f55a22cfc0bc8b62a8588afe2c8b2ca.zip | |
Box arrays of parameter bounds
Diffstat (limited to 'src/comp/metadata/decoder.rs')
| -rw-r--r-- | src/comp/metadata/decoder.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/comp/metadata/decoder.rs b/src/comp/metadata/decoder.rs index 8271c5d9849..49536b6e1c9 100644 --- a/src/comp/metadata/decoder.rs +++ b/src/comp/metadata/decoder.rs @@ -117,14 +117,14 @@ fn item_type(item: ebml::doc, this_cnum: ast::crate_num, tcx: ty::ctxt, fn item_ty_param_bounds(item: ebml::doc, this_cnum: ast::crate_num, tcx: ty::ctxt, extres: external_resolver) - -> [@[ty::param_bound]] { + -> @[ty::param_bounds] { let bounds = []; let def_parser = bind parse_external_def_id(this_cnum, extres, _); ebml::tagged_docs(item, tag_items_data_item_ty_param_bounds) {|p| bounds += [tydecode::parse_bounds_data(@ebml::doc_data(p), this_cnum, def_parser, tcx)]; } - bounds + @bounds } fn item_ty_param_count(item: ebml::doc) -> uint { @@ -209,8 +209,8 @@ fn get_type(data: @[u8], def: ast::def_id, tcx: ty::ctxt, let t = item_type(item, this_cnum, tcx, extres); let tp_bounds = if family_has_type_params(item_family(item)) { item_ty_param_bounds(item, this_cnum, tcx, extres) - } else { [] }; - ret @{bounds: tp_bounds, ty: t}; + } else { @[] }; + ret {bounds: tp_bounds, ty: t}; } fn get_type_param_count(data: @[u8], id: ast::node_id) -> uint { |
