https://kotlinlang.org logo
m

max.

01/22/2017, 3:13 PM
It turns out that annotating class with Spring
@Repository
does that. Suppose the code below
Copy code
@Repository
class Person {
    val msg = "Hello"
    val prop = useValProperty(msg)
}

fun useValProperty(msg: String): Int {
    println(msg)
    return 42
}
IDEA highlights using
msg
property as
Accessing non-final property msg in constructor