Probably Java 10 will get value types. Are there already plans to support such a construct?
I wonder how value types would affect Kotlins approach to
null handling, since Java’s Optional could become a value class, so that there wouldn’t be any memory overhead. Since Kotlin developers are using mostly Java libs the concept of
Optional could become dominant even in Kotlin code. In any case there are two approaches to null handling. Although I like Kotlins approach, I’m not sure how future proof it will be considering particularly value types. What do think?