auto merge of #12627 : alexcrichton/rust/issue-12623, r=brson

This helps prevent the unfortunate interleavings found in #12623.
This commit is contained in:
bors 2014-03-01 00:36:35 -08:00
commit cb498cc40d
8 changed files with 155 additions and 116 deletions

View file

@ -28,7 +28,7 @@ use t = syntax::parse::token;
/// Highlights some source code, returning the HTML output.
pub fn highlight(src: &str) -> ~str {
let sess = parse::new_parse_sess();
let handler = diagnostic::mk_handler();
let handler = diagnostic::default_handler();
let span_handler = diagnostic::mk_span_handler(handler, sess.cm);
let fm = parse::string_to_filemap(sess, src.to_owned(), ~"<stdin>");