Rollup merge of #103870 - TaKO8Ki:fix-103790, r=fee1-dead
Fix `inferred_kind` ICE Fixes #103790
This commit is contained in:
commit
5784a038fb
3 changed files with 78 additions and 0 deletions
|
@ -500,6 +500,9 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
|
|||
}
|
||||
GenericParamDefKind::Const { has_default } => {
|
||||
let ty = tcx.at(self.span).type_of(param.def_id);
|
||||
if ty.references_error() {
|
||||
return tcx.const_error(ty).into();
|
||||
}
|
||||
if !infer_args && has_default {
|
||||
tcx.bound_const_param_default(param.def_id)
|
||||
.subst(tcx, substs.unwrap())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue