Files
kotlin-fork/compiler/testData/diagnostics/tests/destructuring/delegationInDestructuring.kt
T
Anastasia.Nekrasova 1d817e2ace [K2]: Missing error and miscompilation in destructuring declaration delegation
In convertDestructingDeclaration, property delegates are mistakenly
treated as valid expressions for destructuring, but they should be
ignored.

#KT-65021 Fixed
2024-01-29 07:56:43 +00:00

7 lines
323 B
Kotlin
Vendored

// WITH_STDLIB
fun foo() {
<!INITIALIZER_REQUIRED_FOR_DESTRUCTURING_DECLARATION!>val (a, b) by <!DEBUG_INFO_MISSING_UNRESOLVED!>listOf<!>(1, 2)<!>
<!INITIALIZER_REQUIRED_FOR_DESTRUCTURING_DECLARATION!>val (c, d) by <!DEBUG_INFO_MISSING_UNRESOLVED!>lazy<!> { <!DEBUG_INFO_MISSING_UNRESOLVED!>listOf<!>(3, 4) }<!>
}