Files
Denis Zharkov f1026935a0 Add recovery for properties without name
If property name is parsed on the next line and declaration is invalid
(no receiver/type/initializer), treat that name as it does not belong to property

 #KT-12987 In Progress
2016-07-08 16:06:47 +03:00

42 lines
497 B
Kotlin
Vendored

fun foo() {
val
println("abc")
val
lambdaCall {
}
val
if (1 == 1) {
}
val
(1 + 2)
// `propertyNameOnTheNextLine` parsed as simple name expression
val
propertyNameOnTheNextLine
val
// comment
propertyNameOnTheNextLine
val /* comment */
propertyNameOnTheNextLine
// Correct properties
val
property1 = 1
val
propertyWithBy by lazy { 1 }
val
propertyWithType: Int
val
(a, b) = 1
}