TypeParameterDefinition
always require a DefId
This commit is contained in:
parent
52d8c490a3
commit
594cd84a94
5 changed files with 8 additions and 8 deletions
|
@ -265,9 +265,9 @@ impl<'tcx> InferCtxt<'tcx> {
|
|||
kind: UnderspecifiedArgKind::Type {
|
||||
prefix: "type parameter".into(),
|
||||
},
|
||||
parent: def_id.and_then(|def_id| {
|
||||
InferenceDiagnosticsParentData::for_def_id(self.tcx, def_id)
|
||||
}),
|
||||
parent: InferenceDiagnosticsParentData::for_def_id(
|
||||
self.tcx, def_id,
|
||||
),
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1110,7 +1110,7 @@ impl<'tcx> InferCtxt<'tcx> {
|
|||
TypeVariableOrigin {
|
||||
kind: TypeVariableOriginKind::TypeParameterDefinition(
|
||||
param.name,
|
||||
Some(param.def_id),
|
||||
param.def_id,
|
||||
),
|
||||
span,
|
||||
},
|
||||
|
|
|
@ -123,7 +123,7 @@ pub enum TypeVariableOriginKind {
|
|||
NormalizeProjectionType,
|
||||
TypeInference,
|
||||
OpaqueTypeInference(DefId),
|
||||
TypeParameterDefinition(Symbol, Option<DefId>),
|
||||
TypeParameterDefinition(Symbol, DefId),
|
||||
|
||||
/// One of the upvars or closure kind parameters in a `ClosureSubsts`
|
||||
/// (before it has been determined).
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue