Files
kotlin-fork/compiler/testData/diagnostics/tests/incompleteCode/diagnosticWithSyntaxError/checkBackingFieldException.kt
T
Andrey Zinovyev b9ae22207e [FIR] Fix tests data for diagnostic tests
For tests failed after light tree changes
2021-04-20 18:13:03 +03:00

19 lines
433 B
Kotlin
Vendored

package h
class Square() {
var size : Double =
<!UNRESOLVED_REFERENCE!>set<!>(<!UNRESOLVED_REFERENCE!>value<!>) {
//in LT this LAMBDA_EXPRESSION get parsed lazyly, but doesn't got anywhere in FIR tree (as property doesn't have place for it)
<!SYNTAX!>$area<!> <!SYNTAX!>= size * size<!>
}
<!MUST_BE_INITIALIZED_OR_BE_ABSTRACT!>var area : Double<!>
private set
}
fun main() {
val s = Square()
s.size = 2.0
}