Commit delegation expression's trace with errors if we couldn't extract type info for it

^KT-44843 Fixed
This commit is contained in:
Victor Petukhov
2021-09-22 13:50:13 +03:00
parent 561ef5947a
commit 2bdbbdd1a7
8 changed files with 107 additions and 3 deletions
@@ -560,7 +560,11 @@ class DelegatedPropertyResolver(
traceToResolveDelegatedProperty, false, delegateExpression, ContextDependency.DEPENDENT
)
var delegateType = delegateTypeInfo.type ?: return null
var delegateType = delegateTypeInfo.type ?: run {
traceToResolveDelegatedProperty.commit()
return null
}
var delegateDataFlow = delegateTypeInfo.dataFlowInfo
val delegateTypeConstructor = delegateType.constructor