Hacker News new | ask | show | jobs
by unfamiliar 3767 days ago
How so? Doesn't this port to Android show that a Windows port is surely possible? Swift is already running on servers afaik. As for compiling to "browser," Swift is based on LLVM so should be just as capable of this as C++.
1 comments

What's "possible" and what's available and tested in production right now are two very different things. These kinds of ports take at least a year to get over the initial troubles and become usable and then you're at least that time away from a decent size of community libraries to spring up for the mentioned platforms.

By that time Rust will also mature enough and webasm will land so Rust will probably be a better candidate (since it's OSS and developed by a browser company that needs to run on as many platforms as possible they have much better incentives to maintain ports than Apple).

Also in that time C++ will probably get modules working on clang and many c++17 features.

And you might see Xamarin merge into CoreCLR and rolled up into VS integration.

A lot of things are possible - but what's available right now is C++ on every platform and not much else.

What's the canonical way of targeting Android with C++?
Write shared logic in C++ and use JNI/JNA ? Or are you asking about something more specific ?
I guess I found what I was asking about, i.e. NDK: http://developer.android.com/ndk/index.html