1
Fork 0

Remove dummy_config

This commit is contained in:
bjorn3 2021-03-28 18:36:53 +02:00
parent cab940e848
commit b5e049de08
2 changed files with 43 additions and 65 deletions

View file

@ -1591,7 +1591,7 @@ pub enum IncrCompSession {
InvalidBecauseOfErrors { session_directory: PathBuf },
}
pub fn early_error(output: config::ErrorOutputType, msg: &str) -> ! {
pub fn early_error_no_abort(output: config::ErrorOutputType, msg: &str) {
let emitter: Box<dyn Emitter + sync::Send> = match output {
config::ErrorOutputType::HumanReadable(kind) => {
let (short, color_config) = kind.unzip();
@ -1603,6 +1603,10 @@ pub fn early_error(output: config::ErrorOutputType, msg: &str) -> ! {
};
let handler = rustc_errors::Handler::with_emitter(true, None, emitter);
handler.struct_fatal(msg).emit();
}
pub fn early_error(output: config::ErrorOutputType, msg: &str) -> ! {
early_error_no_abort(output, msg);
rustc_errors::FatalError.raise();
}