Skip to content
Better HN
Top
Best
Ask
Show
New
Jobs
Search
⌘K
0 points
zvrba
4y ago
0 comments
Save
Share
> Note that in Kotlin the return type is `Int?`, not `Int`.
How does that fare with unnecessary boxing of primitives?
0 comments
2 comments · 1 top-level
top
newest
oldest
kreetx
4y ago
· 1 in thread
If the function isn't total (as in: for every string there is an int) then the boxing is necessary, no?
zvrba
OP
4y ago
Not if you have user-defined value types (soon coming to Java).
j
/
k
navigate · click thread line to collapse