3 ms·
GC is problematic for cross-language foundational libraries though (unless they run on the same VM of course).
by gpderetta 1y ago
GC is problematic for cross-language foundational libraries though (unless they run on the same VM of course).
- PaulHoule 1y agoBut what’s so bad about that Clojure and Java make a great team.
- Grikbdl 1y agoYeah but now try to make your Java library useful to a C#, Go or Python application.
- PaulHoule 1y agoIn the case of Python I think you could produce something like Jython that runs inside the Java runtime and lines up https://openjdk.org/jeps/454 https://openjdk.org/jeps/454 with the Python FFA so you could run things like numpy inside of it. Would be transformative for my side projects.
- gpderetta 1y agoNothing, hence my "unless they run on the same VM" comment.
- gwbas1c 1y agoMakes me wonder how easy/hard it is to write a library in Rust and expose it to other languages.
- steveklabnik 1y agoCan be viewed as either, you expose a C ABI and then the other languages can use it, which is fundamentally not super hard but fiddly, which could be viewed as hard but some languages have nice libraries that exist to make it easier, which is of course easier.
- tialaramex 1y agoOne extreme case of this would be rustls-openssl-compat which is basically what if you take a Rust TLS implementation but you give it the same ABI as the openssl C library so (where this works, which is far from everywhere) it's a drop-in replacement. e.g. you can run curl, and go fetch https://example.com/ https://example.com/ but using this ersatz openssl rather than your C openssl implementation. That's a thing which works today, albeit not a supported configuration from the point of view of Curl's author.