Skip to content

Commit b44315c

Browse files
committed
Rename EarlyErrorHandler as EarlyDiagCtxt.
1 parent 576b921 commit b44315c

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

src/base.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ pub(crate) fn compile_fn(
176176
match module.define_function(codegened_func.func_id, context) {
177177
Ok(()) => {}
178178
Err(ModuleError::Compilation(CodegenError::ImplLimitExceeded)) => {
179-
let handler = rustc_session::EarlyErrorHandler::new(
179+
let handler = rustc_session::EarlyDiagCtxt::new(
180180
rustc_session::config::ErrorOutputType::default(),
181181
);
182182
handler.early_error(format!(

src/pretty_clif.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -231,9 +231,8 @@ pub(crate) fn write_ir_file(
231231
let res = std::fs::File::create(clif_file_name).and_then(|mut file| write(&mut file));
232232
if let Err(err) = res {
233233
// Using early_warn as no Session is available here
234-
let handler = rustc_session::EarlyErrorHandler::new(
235-
rustc_session::config::ErrorOutputType::default(),
236-
);
234+
let handler =
235+
rustc_session::EarlyDiagCtxt::new(rustc_session::config::ErrorOutputType::default());
237236
handler.early_warn(format!("error writing ir file: {}", err));
238237
}
239238
}

0 commit comments

Comments
 (0)