From e7e6f396d888574e7184119818ac3300f10aacbf Mon Sep 17 00:00:00 2001 From: Marijn Haverbeke Date: Thu, 24 Mar 2011 16:33:20 +0100 Subject: Preserve comments when pretty-printing. The patch also includes a number of smaller fixes to the pretty-printer that were encountered on the way. --- src/comp/driver/rustc.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/comp/driver') diff --git a/src/comp/driver/rustc.rs b/src/comp/driver/rustc.rs index 4c6da407..9ab21622 100644 --- a/src/comp/driver/rustc.rs +++ b/src/comp/driver/rustc.rs @@ -77,7 +77,7 @@ impure fn pretty_print_input(session.session sess, auto def = tup(0, 0); auto p = front.parser.new_parser(sess, env, def, input); auto crate = front.parser.parse_crate_from_source_file(p); - pretty.pprust.print_ast(crate.node.module, std.io.stdout()); + pretty.pprust.print_file(crate.node.module, input, std.io.stdout()); } fn warn_wrong_compiler() { -- cgit v1.2.3