add FIXME for things that I couldn't find ways to trigger

This commit is contained in:
Boxy 2022-11-22 12:20:05 +00:00 committed by kadmin
parent 4833ce8673
commit e58b932daf
2 changed files with 5 additions and 3 deletions

View File

@ -31,6 +31,7 @@ pub fn is_const_evaluatable<'tcx>(
let tcx = infcx.tcx;
let uv = match ct.kind() {
ty::ConstKind::Unevaluated(uv) => uv,
// FIXME(generic_const_exprs): this seems wrong but I couldn't find a way to get this to trigger
ty::ConstKind::Expr(_) => bug!("unexpected expr in `is_const_evaluatable: {ct:?}"),
ty::ConstKind::Param(_)
| ty::ConstKind::Bound(_, _)

View File

@ -476,9 +476,10 @@ fn compute(&mut self, arg: GenericArg<'tcx>) {
ty::Binder::dummy(ty::PredicateKind::WellFormed(ct.into())),
));
}
// FIXME(julianknodt): need to infer any nested consts here
// so walk and search recursively?
ty::ConstKind::Expr(_) => unimplemented!(),
// FIXME(generic_const_exprs): This seems wrong but I could not find a way to get this to trigger
ty::ConstKind::Expr(_) => {
bug!("checking wfness of `ConstKind::Expr` is unsupported")
}
ty::ConstKind::Error(_)
| ty::ConstKind::Param(_)