diff --git a/compiler/rustc_const_eval/src/interpret/validity.rs b/compiler/rustc_const_eval/src/interpret/validity.rs index 224337e68cfbf..aac1dfa4a3cb8 100644 --- a/compiler/rustc_const_eval/src/interpret/validity.rs +++ b/compiler/rustc_const_eval/src/interpret/validity.rs @@ -995,7 +995,9 @@ impl<'rt, 'tcx, M: Machine<'tcx>> ValidityVisitor<'rt, 'tcx, M> { // Nothing to check. interp_ok(true) } - ty::UnsafeBinder(_) => todo!("FIXME(unsafe_binder)"), + // Unsafe binders are compound: validate the inner value (same as other + // non-primitive types that are not layout-less). + ty::UnsafeBinder(_) => interp_ok(false), // The above should be all the primitive types. The rest is compound, we // check them by visiting their fields/variants. ty::Adt(..)