TimeRangePicker icon indicating copy to clipboard operation
TimeRangePicker copied to clipboard

Don't use nullable types on primitive to avoid tons of (un)boxing

Open pelmenstar1 opened this issue 3 years ago • 2 comments

Type Int? in Kotlin JVM maps to reference type Integer. It causes memory allocations. In our case, nullability isn't necessary and can be avoided.

To save compatibility with the last version of the library, some variables types are explicitly marked.

Maybe we should break compatibility and then, boxed types won't be used at all.

pelmenstar1 avatar Jul 15 '21 10:07 pelmenstar1

Looks good and in my opinion, it is okay to break compatibility for this, if you want to, of course, otherwise I will accept it as-is.

Droppers avatar Aug 27 '21 20:08 Droppers

Conflicts fixed!

pelmenstar1 avatar Sep 10 '21 18:09 pelmenstar1