I would strongly recommend IntelliJ with intellij-rust. It's the most complete IDE-like experience currently.
But any editor works, really. IJ is a bit on the heavy side, but is still much lighter than, say, VS
I would strongly recommend IntelliJ with intellij-rust. It's the most complete IDE-like experience currently.
But any editor works, really. IJ is a bit on the heavy side, but is still much lighter than, say, VS
Lighter than visual studio or visual studio code? Because IntelliJ idea takes a long time to open.
What features would you define as ide like?
Lighter than VS, but much heavier than VS Code.
As for features:
cargo build
every time a dependency changes to get autocomplete for it;if
/else if
chains to match
, expand elided lifetimes, etc)Well, that seems like a nice list. I will give a good try the day I have a real project (more than what I usually do).
I don't do anything where I need those kind of features. Right now I almost exclusively work on my server so I use vim with a lot of plugins (and I simply like vim, but wouldn't use it for anything too big I think)
It is a tradeoff between speed and features. You can't expect any IDE to have a lot of features and still work fast.
Perfect case for Rust to address? :)
Perfect case for Rust to address? :)
Not a bad idea though it will take a long time to build. If we can start a community-written IDE it will be amazing.
Noooo! Don't RIIR!
There's a lot of things that need the Rust-treatment way harder than IDE's. Lets focus our few developers there, instead of reinventing (already highly capable) wheels!
Security-critical, tightly optimised things like browsers, compressions libraries or parsing of untrusted web video!
Well, my question was a joke
That's the dangerous thing about the internet! You can never be sure!
Yeah i agree with that. I don't want to rewrite everything in Rust but in this case the performance might have a boost compared to IDE written in Java. just a thought
Just to clarify, intellij-rust
itself is actually all written in Kotlin, which normally runs on the JVM. I was actually surprised to see that IntelliJ itself is still mostly Java. I would have thought that would be mostly ported to Kotlin by now. (@matklad, curious if you have insights about % Kotlin use in other JetBrains products).
Of course this isn't a big difference as they both run on the JVM and are garbage collected. But I imagine that perhaps one day, JetBrains could use Kotlin Native to compile it's IDEs to native through LLVM, just like Rust (but still having GC overhead and such).
Well, there are almost five million lines of Java in IntelliJ community, if tokei
is counting correctly. You'll need a bit of time to convert this lot into another language And, actually, it's not necessary, because interop between Kotlin and Java is completely seamless, so there's no need to convert anything. However, a lot of new code is written in Kotlin.
It is not easy to port from one language to the other especially on a product with so many users.
Just for reference, this is how to use cargo to check code. I've just today started learning Rust and using intelliJ. So took me a few minutes to find. Maybe it will save someone time though.
On a IDE related note, the docs mention cargo build --release
for production code. But I wasn't sure how to build within intelliJ and use this parameter. So just wondered if anyone knew?
It’ll be interesting to see what type of performance Kotlin Native will yield eventually. Java is performant only because of JVMs with a PGO’d JIT - the language is otherwise performance anemic (and hostile even in some regards).
Rust Enhanced has "experimental" RLS Support. (Check readme)
https://github.com/rust-lang/rust-enhanced#rls
There's still quite a bit to do, but you can play with it today
Does Intellij Rust plugin have feature that automatically modifies mod files when you add a new file to that directory? This would be really helpful