This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pub fn rewrite_tuple_struct_or_variant_calls(c: &Crate, dm: DefMap) -> @Crate { | |
fn fold_expr(e: &ast::expr_, fld: @fold::ast_fold, dm: DefMap) -> Option<ast::expr_> { | |
let fold_unnamed_field = |x| { | |
ast::Field { | |
ident: special_idents::unnamed_field, | |
expr: fld.fold_expr(x), | |
span: fld.new_span(x.span), | |
} | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/librustc/middle/trans/callee.rs b/src/librustc/middle/trans/callee.rs | |
index d64615e..4a8b779 100644 | |
--- a/src/librustc/middle/trans/callee.rs | |
+++ b/src/librustc/middle/trans/callee.rs | |
@@ -124,16 +124,6 @@ pub fn trans(bcx: @mut Block, expr: @ast::expr) -> Callee { | |
trait_did, | |
ref_expr.id)) | |
} | |
- ast::def_variant(tid, vid) => { | |
- // nullary variants are not callable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct Node(uint, uint); | |
struct Nobe { fst: uint, snd: uint } | |
fn main() { | |
let foo = Node(17, 42); | |
let bar = Nobe{fst: 17, snd: 42}; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extern mod syntax; | |
extern mod extra; | |
use syntax::ast::{item, item_mod}; | |
use syntax::parse::{new_parse_sess, new_parser_from_file}; | |
use syntax::parse::parser::Parser; | |
use syntax::codemap::FileName; | |
use std::os; | |
use extra::sort; |
NewerOlder