convert ast::{field_,capture_item_,mt} and middle::ty::mt into structs
This commit is contained in:
@@ -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 {
|
||||
|
||||
Reference in New Issue
Block a user