1
Fork 0

Make fatal errors more consistent.

This commit is contained in:
Eli Friedman 2015-10-23 19:42:42 -07:00
parent 329e487e58
commit e5024924ad
7 changed files with 23 additions and 27 deletions

View file

@ -235,7 +235,7 @@ fn file_to_filemap(sess: &ParseSess, path: &Path, spanopt: Option<Span>)
let msg = format!("couldn't read {:?}: {}", path.display(), e);
match spanopt {
Some(sp) => panic!(sess.span_diagnostic.span_fatal(sp, &msg)),
None => sess.span_diagnostic.handler().fatal(&msg)
None => panic!(sess.span_diagnostic.handler().fatal(&msg))
}
}
}