[NI] Fix recursion in contract declaration analysis.
#KT-30410 Fixed
This commit is contained in:
+2
@@ -55,6 +55,8 @@ interface KotlinResolutionCallbacks {
|
||||
val inferenceSession: InferenceSession
|
||||
|
||||
fun getExpectedTypeFromAsExpressionAndRecordItInTrace(resolvedAtom: ResolvedCallAtom): UnwrappedType?
|
||||
|
||||
fun disableContractsIfNecessary(resolvedAtom: ResolvedCallAtom)
|
||||
}
|
||||
|
||||
interface SamConversionTransformer {
|
||||
|
||||
+4
-1
@@ -133,7 +133,10 @@ class KotlinCallCompleter(
|
||||
val candidate = candidates.singleOrNull()
|
||||
|
||||
// this is needed at least for non-local return checker, because when we analyze lambda we should already bind descriptor for outer call
|
||||
candidate?.resolvedCall?.let { resolutionCallbacks.bindStubResolvedCallForCandidate(it) }
|
||||
candidate?.resolvedCall?.let {
|
||||
resolutionCallbacks.bindStubResolvedCallForCandidate(it)
|
||||
resolutionCallbacks.disableContractsIfNecessary(it)
|
||||
}
|
||||
|
||||
return candidate ?: factory.createErrorCandidate().forceResolution()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user