about summary refs log tree commit diff
path: root/compiler/rustc_codegen_ssa/src/errors.rs
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2024-02-10 13:12:31 +0100
committerGitHub <noreply@github.com>2024-02-10 13:12:31 +0100
commit9a8958f2bb9e2a9f7440226c23213725b4d777fa (patch)
tree14bd4f1285eb48114bf91dde508be653ba680224 /compiler/rustc_codegen_ssa/src/errors.rs
parent2dbc9f55f76aac46c0e9ed31b60d8c2960d2f5f0 (diff)
parent3d4a9f504780dd8f9ba4e7921cce8d8517c20aa6 (diff)
downloadrust-9a8958f2bb9e2a9f7440226c23213725b4d777fa.tar.gz
rust-9a8958f2bb9e2a9f7440226c23213725b4d777fa.zip
Rollup merge of #120865 - saethlin:missing-o-files, r=nnethercote
Turn the "no saved object file in work product" ICE into a translatable fatal error

I don't know if it's fair to say this fixes https://github.com/rust-lang/rust/issues/120854 but it surely makes the error reporting better and should encourage people with good instincts like ```@CinchBlue.```
Diffstat (limited to 'compiler/rustc_codegen_ssa/src/errors.rs')
-rw-r--r--compiler/rustc_codegen_ssa/src/errors.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/compiler/rustc_codegen_ssa/src/errors.rs b/compiler/rustc_codegen_ssa/src/errors.rs
index 06ea5b9e8f4..3d7903b5efb 100644
--- a/compiler/rustc_codegen_ssa/src/errors.rs
+++ b/compiler/rustc_codegen_ssa/src/errors.rs
@@ -122,6 +122,12 @@ pub struct NoNatvisDirectory {
 }
 
 #[derive(Diagnostic)]
+#[diag(codegen_ssa_no_saved_object_file)]
+pub struct NoSavedObjectFile<'a> {
+    pub cgu_name: &'a str,
+}
+
+#[derive(Diagnostic)]
 #[diag(codegen_ssa_copy_path_buf)]
 pub struct CopyPathBuf {
     pub source_file: PathBuf,