Richard Green
06/28/2018, 12:58 PMobject M {
class C (val x: Int, val y: Int = 5)
}
class N(val x: Int, val y: Int = 5)
fun main(args: Array<String>) {
val p = N(3)
val q = (M::C)(3)
}
Why is there a syntax error in the val q = line ?Lucas Ł
06/28/2018, 1:02 PMval q = M.C(3)
(a)(b)
syntax, means that you are trying to cast b
to a
. Not sure about that though 🙂