News for hackers. Stuff that matters.
Re:E.W.Dijkstra: Simplicity is a great virtue ... complexity... by tbrownaw on Wednesday December 25, 2024 @12:28PM (#42509870)
> It's actually really weird, if you think about it, that point 1 should involve the network. We should be able to just call a function in one language from a function in another language.

If you have two languages that both are not C or C++ , and have more involved runtimes, how well does this work? I know for some cases you have things like JRuby or IronPython, but say mixing a JVM language and a CLR language?

Re:E.W.Dijkstra: Simplicity is a great virtue ... complexity... by whstl on Wednesday December 25, 2024 @10:03PM (#42512844)
For those cases you have to bring the runtimes with you.

With JVM and CLR you can use JNI and COM to generate SOs/DLLs, and both of them can use any SOs/DLLs via FFI. There is also IKVM and Jni4Net that allowed Java code to run in .NET (or at least used to be, I last used it 15 years ago). Results may vary.

For other languages it can be a bit more involved: if there's no such thing as exposing as a library, you must embed the interpreter, which typically involves using C++.

It's not fun. This is why people end up using network requests.

If you can have a text-only interface, or even involve files, you can also just invoke the other app as a process.