Skip to content

Commit

Permalink
Remove old box syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
Alex HotShot Newman committed May 20, 2015
1 parent e38a672 commit 2fbb445
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/lib.rs
Expand Up @@ -8,8 +8,6 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.

#![feature(box_syntax)]
#![feature(box_patterns)]
#![feature(rustc_private)]
#![feature(collections)]
#![feature(str_char)]
Expand Down Expand Up @@ -224,7 +222,7 @@ impl<'a> CompilerCalls<'a> for RustFmtCalls {
let write_mode = self.write_mode;
let mut control = driver::CompileController::basic();
control.after_parse.stop = Compilation::Stop;
control.after_parse.callback = box move |state| {
control.after_parse.callback = Box::new(move |state| {
let krate = state.krate.unwrap();
let codemap = state.session.codemap();
let mut changes = fmt_ast(krate, codemap);
Expand All @@ -244,7 +242,7 @@ impl<'a> CompilerCalls<'a> for RustFmtCalls {
}
}
}
};
});

control
}
Expand Down

0 comments on commit 2fbb445

Please sign in to comment.