@@ -141,9 +141,10 @@ pub enum InvalidProgramInfo<'tcx> {
141141 AlreadyReported ( ErrorReported ) ,
142142 /// An error occurred during layout computation.
143143 Layout ( layout:: LayoutError < ' tcx > ) ,
144- /// An error occurred during FnAbi computation.
145- /// (Not using `FnAbiError` as that contains a nested `LayoutError`.)
146- FnAbi ( call:: AdjustForForeignAbiError ) ,
144+ /// An error occurred during FnAbi computation: the passed --target lacks FFI support
145+ /// (which unfortunately typeck does not reject).
146+ /// Not using `FnAbiError` as that contains a nested `LayoutError`.
147+ FnAbiAdjustForForeignAbi ( call:: AdjustForForeignAbiError ) ,
147148 /// An invalid transmute happened.
148149 TransmuteSizeDiff ( Ty < ' tcx > , Ty < ' tcx > ) ,
149150 /// SizeOf of unsized type was requested.
@@ -160,7 +161,7 @@ impl fmt::Display for InvalidProgramInfo<'_> {
160161 write ! ( f, "encountered constants with type errors, stopping evaluation" )
161162 }
162163 Layout ( ref err) => write ! ( f, "{}" , err) ,
163- FnAbi ( ref err) => write ! ( f, "{}" , err) ,
164+ FnAbiAdjustForForeignAbi ( ref err) => write ! ( f, "{}" , err) ,
164165 TransmuteSizeDiff ( from_ty, to_ty) => write ! (
165166 f,
166167 "transmuting `{}` to `{}` is not possible, because these types do not have the same size" ,
0 commit comments