We are developing a Rust extension mechanism for R here:
Rust is likely to be the successor to C++ because of its safety and ease of use.
In particular, it is possible to write domain specific languages within Rust code
and generate wrappers to other languages through procedural macros.
Rust has tens of thousands of excellent packages and it is our hope to be able
to automate the wrapping of general rust packages to provide a vast range of extra
R packages for free.
It would be very nice if we could have some help with RStudio integration including build
testing and CI support.
Hi,
I don't know Rust, but I've heard good things! I just wanted to point out that, if this is a feature request for the IDE, you might want to file it in the RStudio IDE repo:
Nice to hear from you. One of our developers is having build issues under RStudio
and it might be useful to diagnose the problem.
As for an IDE extension, Rust has a number of excellent language servers (RLS and Rust analyser that handle hover events and annotate code with types. It would be an interesting project for someone
to integrate these, but that would be a far bigger ask
Joroen has done some excellent work introducing R users to Rust
using the .C interface, but for this to be useful, we need to be able to
wrap functions and interfaces in an automated way through the .Call
interface which is a lot more complex.
Saying this, the two systems are highly complementary and I've provided
the raw interface, libR-sys so that alternate mechanisms can be supported.
There are a few examples of R -> Rust, but the converse is also possible
as the Rust language is very flexible.
The current task is to generate the R package which integrates the DLL bindings
into R packages. The aim is to make the generation of rust functions as frictionless
as possible.