Hacker News new | ask | show | jobs
by MuffinFlavored 2471 days ago
Libraries only, or can you write native iOS apps 100% in Rust, no Swift?
1 comments

You would need at least a bridging layer (of Objective-C) to so that your app code could use the system frameworks and respond to events (user input, network, sensors, etc).
Objective-C shares calling conventions and struct layout with C, so theoretically you could directly call the system frameworks from Rust via extern "C" functions.
Not even theoretically, the bindings for the runtime are out there [1] with some nifty helper macros.

[1] https://github.com/SSheldon/rust-objc

It'd be super cool to see a 100% Rust (with extern "C" calls) Hello, world! iOS compatible app.