Re:Go 1.6 is Released
by merb on Thursday February 18, 2016 @03:20AM
(#11124419)
Actually JNA is actually way better than Go or JNI.
And if you are looking at Kotlin / Scala you won't find yourself inside the object-oriented pain. The JVM is actually not that bad.
[ Parent
| on HN ]
I agree with you. But this code, does not compile
List<Integer>[] j=new List<Integer>[10];
and this is a a serious problem. If generics are correctly implemented, then it should compile.
That's because List is an interface, not a class. FYI this works in Scala:
val j = List(1, 2, 3)
It doesn't work for all scala interfaces, and when it is like that, it's often frustrating to find the underlying implementation.
But that's beside the point—OP was pointing out that you can't have generic allocation.