How to integrate Rust with Visual Studio 2019

I installed Rust Compiler as well as VS 2019 and the Rust ext for VS 2019 from the Microsoft Market place.

When I create a new project in VS 2019, it has no option for RUST project type. My question is how I can integrate Rust with VS 2019? What else is to be done please.

1 Like

I have the same needs as you. I use VSCode offline now, It works well.

1 Like

I tried this and the VS2017 plug in for VIsual Studio doesn't appear to work well with VS2019.
(I have 16.5.4 and 16.10.3 currently. ) I think that doing some digging into the VS2017 plug-in sources (if they are open source) one could determine what the plug-in "does" and then using C# code a VS2019 plug-in that works. So thats on my radar... but as a RUST newbie at the moment, I'm just starting via brute force. I use VS2019 as an EDITOR only (open folder technique), and this seems to work fine for edits. Then I run powershell for builds.

I find that name munging on our C/C++ API requires some tricks to get cargo to both link to native C/C++ API's and be called from a C/C++ main, but I have been able to create a "hello world" DLL in RUST that calls a native API with varargs to send messages and it's called from 'C'.
The fact that I'm able to get that far so soon, is really impressive.