diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2023-08-04 21:31:57 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-08-04 21:31:57 +0200 |
| commit | a0fd747e3813de817c716fa51bb07229d84bdbd5 (patch) | |
| tree | c6a10e666e194b9c2b53f4fa9b441b56e68df592 /compiler/rustc_codegen_gcc | |
| parent | 99e4127d8506656b0a414728a809e64e3414886c (diff) | |
| parent | 3d25b5c7e8653a4ce0513cf8d7bcbd796ed81c4b (diff) | |
| download | rust-a0fd747e3813de817c716fa51bb07229d84bdbd5.tar.gz rust-a0fd747e3813de817c716fa51bb07229d84bdbd5.zip | |
Rollup merge of #114450 - chenyukang:yukang-fix-114435, r=compiler-errors
Fix ICE failed to get layout for ReferencesError Fixes #114435 r? `@compiler-errors`
Diffstat (limited to 'compiler/rustc_codegen_gcc')
| -rw-r--r-- | compiler/rustc_codegen_gcc/src/context.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_codegen_gcc/src/context.rs b/compiler/rustc_codegen_gcc/src/context.rs index 08507e19652..88dcafa7370 100644 --- a/compiler/rustc_codegen_gcc/src/context.rs +++ b/compiler/rustc_codegen_gcc/src/context.rs @@ -476,7 +476,7 @@ impl<'gcc, 'tcx> LayoutOfHelpers<'tcx> for CodegenCx<'gcc, 'tcx> { #[inline] fn handle_layout_err(&self, err: LayoutError<'tcx>, span: Span, ty: Ty<'tcx>) -> ! { - if let LayoutError::SizeOverflow(_) = err { + if let LayoutError::SizeOverflow(_) | LayoutError::ReferencesError(_) = err { self.sess().emit_fatal(respan(span, err.into_diagnostic())) } else { span_bug!(span, "failed to get layout for `{}`: {}", ty, err) |
