Hacker News new | ask | show | jobs
by stiGGG 2982 days ago
I am not very optimistic that this would ever be a big thing. I see two possibilities how this could happen:

1. Someone would write a 100% source compatible swift version for the JVM or at least a large enough subset leaving out the parts which handles memory directly.

2. Someone develops an easy to use framework to bridge Swift through the NDK (There would be a layer of C needed to talk from Swift to the JVM code and vice versa).

Option 2 is the more realistic approach i guess, but this would heavily effect the architecture of the apps built with this. Everyone who has tried to do the same with C++ (which is supported from the NDK directly) and wanted to have as much code platform independent as possible knows that.

I see the use of Kotlin Native more promising here in the future. As far as i know they have already interoperability with Obj-C / Swift implemented. You could write your Android App completely in Kotlin leaving out the horrible NDK part, because everything is running on the JVM and use Kotlin Native + Swift in the iOS version.