ararslan / julia-rs

Call Julia from Rust
MIT License
16 stars 3 forks source link

Call for collaborators #1

Open ararslan opened 7 years ago

ararslan commented 7 years ago

I'd like to formally request assistance with planning and/or implementing this. Even a few pointers would be great.

Anyone and everyone is welcome to contribute, of course, but in particular I was wondering if perhaps @iamed2 or one of the other fine Invenia folks would be interested. You seem like a bunch of awesome people who know what they're doing with both Julia and Rust, being the authors of Rust.jl.

So if anyone is interested, let me know!

iamed2 commented 7 years ago

I've got a lot on the go right now but I'm happy to provide advice and input. To start, this is most of what you'll need to know: http://docs.julialang.org/en/latest/manual/embedding/

PallHaraldsson commented 7 years ago

This link works: http://docs.julialang.org/en/stable/manual/embedding/

[I guess the other one also did (and you've read); strange that "latest" has been dropped.]

I guess in many ways, embedding Julia in Rust works them same as in C (as both have manual memory management). I haven't yet looked at Rust in detail, but is there no conflict with the ownership model? Can you embedd but not somehow use all the features?

Does it work better (or worse) then embedding Rust under Julia? Embedding C (really just calling functions) in Julia seems the easiest. Isn't that again more complicated for Rust?

[Compared to embedding a GC language under Julia, Rust, at least C, seems simpler, as there's a conflict and it seems the master language gets to have the GC and the embedded language's one disabled. I think that is how PyCall.jl works (maybe reference counting still retained there, just cycle GC disabled); for a separate process, as with JavaCall.jl this doesn't apply.]