Dizarray
12/04/2017, 4:28 AMclass DefaultList(val name: String = "", val friends: List<String>)
class ListDefault(val friends: List<String>, val name: String = "")
fun foo() {
val instance = DefaultList(arrayListOf("blah"))
val another = ListDefault(arrayListOf("blah"))
}
Line, where I create instance
variable doesn't compile. But line with creating another
variable is ok. Do I really need to have a variable with default value at the end of primary constructor or is it a bug?Czar
12/04/2017, 6:17 AM