https://kotlinlang.org logo
#announcements
Title
# announcements
s

sreich

04/07/2017, 9:24 PM
m

marcinmoskala

04/11/2017, 11:12 PM
I am not sure what is the adventage of using this:
Copy code
object Coord : Strukt() {
	var x by int()
	var y by int()
}
instead of this:
Copy code
object Coord {
    var x: Int
    var y: Int
}
Have you done any performance tests?
s

sreich

04/11/2017, 11:13 PM
well, you could only have 1 of those, for starters
cheaper allocations basically
and no, i haven't done any perf testing..or even needed to go down that road. i've only been allocating willy nilly (i'll deal with it when it's a problem)
2 Views