convert ast::{field_,capture_item_,mt} and middle::ty::mt into structs

This commit is contained in:
Erick Tryzelaar
2013-01-14 21:36:27 -08:00
parent 4bcd19f6be
commit 293cd3480c
26 changed files with 195 additions and 129 deletions

View File

@@ -146,8 +146,10 @@ impl ext_ctxt: ext_ctxt_ast_builder {
}
fn field_imm(name: ident, e: @ast::expr) -> ast::field {
spanned { node: { mutbl: ast::m_imm, ident: name, expr: e },
span: dummy_sp()}
spanned {
node: ast::field_ { mutbl: ast::m_imm, ident: name, expr: e },
span: dummy_sp(),
}
}
fn rec(+fields: ~[ast::field]) -> @ast::expr {
@@ -158,8 +160,13 @@ impl ext_ctxt: ext_ctxt_ast_builder {
}
fn ty_field_imm(name: ident, ty: @ast::Ty) -> ast::ty_field {
spanned { node: { ident: name, mt: { ty: ty, mutbl: ast::m_imm } },
span: dummy_sp() }
spanned {
node: {
ident: name,
mt: ast::mt { ty: ty, mutbl: ast::m_imm },
},
span: dummy_sp(),
}
}
fn ty_rec(+fields: ~[ast::ty_field]) -> @ast::Ty {