Skip to content

Commit 1fd735d

Browse files
author
James Miller
committed
Fix broken tests
1 parent fb19205 commit 1fd735d

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

src/libsyntax/fold.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -964,7 +964,7 @@ mod test {
964964
}
965965

966966
// this version doesn't care about getting comments or docstrings in.
967-
fn fake_print_crate(s: @pprust::ps, crate: ast::crate) {
967+
fn fake_print_crate(s: @pprust::ps, crate: &ast::crate) {
968968
pprust::print_mod(s, &crate.node.module, crate.node.attrs);
969969
}
970970

@@ -995,7 +995,7 @@ mod test {
995995
let ast = string_to_crate(@"#[a] mod b {fn c (d : e, f : g) {h!(i,j,k);l;m}}");
996996
assert_pred!(matches_codepattern,
997997
"matches_codepattern",
998-
pprust::to_str(zz_fold.fold_crate(ast),fake_print_crate,
998+
pprust::to_str(&zz_fold.fold_crate(ast),fake_print_crate,
999999
token::get_ident_interner()),
10001000
~"#[a]mod zz{fn zz(zz:zz,zz:zz){zz!(zz,zz,zz);zz;zz}}");
10011001
}
@@ -1007,7 +1007,7 @@ mod test {
10071007
=> (g $(d $d $e)+))} ");
10081008
assert_pred!(matches_codepattern,
10091009
"matches_codepattern",
1010-
pprust::to_str(zz_fold.fold_crate(ast),fake_print_crate,
1010+
pprust::to_str(&zz_fold.fold_crate(ast),fake_print_crate,
10111011
token::get_ident_interner()),
10121012
~"zz!zz((zz$zz:zz$(zz $zz:zz)zz+=>(zz$(zz$zz$zz)+)))");
10131013
}

src/libsyntax/parse/mod.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -482,15 +482,15 @@ mod test {
482482
assert_eq!(parser.parse_arg_general(true),
483483
ast::arg{
484484
is_mutbl: false,
485-
ty: @ast::Ty{id:3, // fixme
485+
ty: ast::Ty{id:3, // fixme
486486
node: ast::ty_path(ast::Path{
487487
span:sp(4,4), // this is bizarre...
488488
// check this in the original parser?
489489
global:false,
490490
idents:~[str_to_ident("int")],
491491
rp: None,
492492
types: ~[]},
493-
@None, 2),
493+
None, 2),
494494
span:sp(4,7)},
495495
pat: @ast::pat{id:1,
496496
node: ast::pat_ident(ast::bind_infer,
@@ -519,14 +519,14 @@ mod test {
519519
node: ast::item_fn(ast::fn_decl{
520520
inputs: ~[ast::arg{
521521
is_mutbl: false,
522-
ty: @ast::Ty{id:3, // fixme
522+
ty: ast::Ty{id:3, // fixme
523523
node: ast::ty_path(ast::Path{
524524
span:sp(10,13),
525525
global:false,
526526
idents:~[str_to_ident("int")],
527527
rp: None,
528528
types: ~[]},
529-
@None, 2),
529+
None, 2),
530530
span:sp(10,13)},
531531
pat: @ast::pat{id:1, // fixme
532532
node: ast::pat_ident(
@@ -542,7 +542,7 @@ mod test {
542542
span: sp(6,7)},
543543
id: 4 // fixme
544544
}],
545-
output: @ast::Ty{id:5, // fixme
545+
output: ast::Ty{id:5, // fixme
546546
node: ast::ty_nil,
547547
span:sp(15,15)}, // not sure
548548
cf: ast::return_val

src/libsyntax/print/pprust.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2272,7 +2272,7 @@ mod test {
22722272

22732273
let decl = ast::fn_decl {
22742274
inputs: ~[],
2275-
output: @ast::Ty {id: 0,
2275+
output: ast::Ty {id: 0,
22762276
node: ast::ty_nil,
22772277
span: codemap::dummy_sp()},
22782278
cf: ast::return_val

0 commit comments

Comments
 (0)