diff options
Diffstat (limited to 'src/libsyntax/fold.rs')
| -rw-r--r-- | src/libsyntax/fold.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/libsyntax/fold.rs b/src/libsyntax/fold.rs index cc3ae025263..fc4f427d8d7 100644 --- a/src/libsyntax/fold.rs +++ b/src/libsyntax/fold.rs @@ -947,24 +947,24 @@ mod test { #[test] fn ident_transformation () { let mut zz_fold = ToZzIdentFolder; let ast = string_to_crate( - ~"#[a] mod b {fn c (d : e, f : g) {h!(i,j,k);l;m}}"); + "#[a] mod b {fn c (d : e, f : g) {h!(i,j,k);l;m}}".to_owned()); let folded_crate = zz_fold.fold_crate(ast); assert_pred!(matches_codepattern, "matches_codepattern", pprust::to_str(|s| fake_print_crate(s, &folded_crate)), - ~"#[a]mod zz{fn zz(zz:zz,zz:zz){zz!(zz,zz,zz);zz;zz}}"); + "#[a]mod zz{fn zz(zz:zz,zz:zz){zz!(zz,zz,zz);zz;zz}}".to_owned()); } // even inside macro defs.... #[test] fn ident_transformation_in_defs () { let mut zz_fold = ToZzIdentFolder; let ast = string_to_crate( - ~"macro_rules! a {(b $c:expr $(d $e:token)f+ => \ - (g $(d $d $e)+))} "); + "macro_rules! a {(b $c:expr $(d $e:token)f+ => \ + (g $(d $d $e)+))} ".to_owned()); let folded_crate = zz_fold.fold_crate(ast); assert_pred!(matches_codepattern, "matches_codepattern", pprust::to_str(|s| fake_print_crate(s, &folded_crate)), - ~"zz!zz((zz$zz:zz$(zz $zz:zz)zz+=>(zz$(zz$zz$zz)+)))"); + "zz!zz((zz$zz:zz$(zz $zz:zz)zz+=>(zz$(zz$zz$zz)+)))".to_owned()); } } |
