Property vs Field

Actually they may or not be. Consider this code which does generate getI and setI methods:

class Foo{
    private var i = 5
    
    fun bar() = this::i.getter
}
2 Likes