FIR checker: report CAPTURED_VAL_INITIALIZATION

This commit is contained in:
Jinseong Jeon
2021-05-11 15:41:56 -07:00
committed by TeamCityServer
parent d38effcbbe
commit f0f1e2d945
20 changed files with 158 additions and 31 deletions
@@ -0,0 +1,11 @@
/*
* Copyright 2010-2021 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
package org.jetbrains.kotlin.fir.resolve.dfa.cfg
import org.jetbrains.kotlin.contracts.description.EventOccurrencesRange
val EventOccurrencesRange?.isInPlace: Boolean
get() = this != null
@@ -306,9 +306,6 @@ class ControlFlowGraphBuilder {
else -> false
}
private val EventOccurrencesRange?.isInPlace: Boolean
get() = this != null
fun exitAnonymousFunction(anonymousFunction: FirAnonymousFunction): Triple<FunctionExitNode, PostponedLambdaExitNode?, ControlFlowGraph> {
val symbol = anonymousFunction.symbol
val exitNode = exitsOfAnonymousFunctions.remove(symbol)!!.also {