@@ -215,7 +215,7 @@ pub enum LayoutError<'tcx> {
215215 SizeOverflow ( Ty < ' tcx > ) ,
216216 NormalizationFailure ( Ty < ' tcx > , NormalizationError < ' tcx > ) ,
217217 ReferencesError ( ErrorGuaranteed ) ,
218- Cycle ,
218+ Cycle ( ErrorGuaranteed ) ,
219219}
220220
221221impl < ' tcx > LayoutError < ' tcx > {
@@ -226,7 +226,7 @@ impl<'tcx> LayoutError<'tcx> {
226226 Unknown ( _) => middle_unknown_layout,
227227 SizeOverflow ( _) => middle_values_too_big,
228228 NormalizationFailure ( _, _) => middle_cannot_be_normalized,
229- Cycle => middle_cycle,
229+ Cycle ( _ ) => middle_cycle,
230230 ReferencesError ( _) => middle_layout_references_error,
231231 }
232232 }
@@ -240,7 +240,7 @@ impl<'tcx> LayoutError<'tcx> {
240240 NormalizationFailure ( ty, e) => {
241241 E :: NormalizationFailure { ty, failure_ty : e. get_type_for_failure ( ) }
242242 }
243- Cycle => E :: Cycle ,
243+ Cycle ( _ ) => E :: Cycle ,
244244 ReferencesError ( _) => E :: ReferencesError ,
245245 }
246246 }
@@ -261,7 +261,7 @@ impl<'tcx> fmt::Display for LayoutError<'tcx> {
261261 t,
262262 e. get_type_for_failure( )
263263 ) ,
264- LayoutError :: Cycle => write ! ( f, "a cycle occurred during layout computation" ) ,
264+ LayoutError :: Cycle ( _ ) => write ! ( f, "a cycle occurred during layout computation" ) ,
265265 LayoutError :: ReferencesError ( _) => write ! ( f, "the type has an unknown layout" ) ,
266266 }
267267 }
@@ -333,7 +333,7 @@ impl<'tcx> SizeSkeleton<'tcx> {
333333 Err ( err @ LayoutError :: Unknown ( _) ) => err,
334334 // We can't extract SizeSkeleton info from other layout errors
335335 Err (
336- e @ LayoutError :: Cycle
336+ e @ LayoutError :: Cycle ( _ )
337337 | e @ LayoutError :: SizeOverflow ( _)
338338 | e @ LayoutError :: NormalizationFailure ( ..)
339339 | e @ LayoutError :: ReferencesError ( _) ,
0 commit comments