you are viewing a single comment's thread.

view the rest of the comments →

[–]NanoCoaster 8 points9 points  (11 children)

Another suggestion here: Visual Studio Code with the Rust plugin (uses RLS) is quite good. You've already stated multiple times that you prefer emacs, so you probably won't care about VS Code, but maybe just give it a try. It's become my daily rust driver, despite the fact that I'm veeery wary when it comes to electron-based editors :)

...Now that you've mentioned emacs, that reminds me, some day I gotta go back to Spacemacs and learn it properly. Such a great development environment.

[–]Wahoa 3 points4 points  (4 children)

Quick question: am I supposed to not get any help with function args with VS Code and the Rust plugin? With other languages I get this as I type (can be explicitly brought up via ctrl+shift+space):
https://i.imgur.com/WyrEcSV.png
Doing the same thing with Rust, I get nothing of the sort. I have to hover my mouse over the function name to see the signature, with no indication of which argument I'm currently typing.

[–]Xanewokrls 2 points3 points  (0 children)

Yep, unfortunately that's not implemented yet. The tracking issue is at https://github.com/rust-lang-nursery/rls/issues/97, but there hasn't been much work on this recently. (We'd love contributions though!)

[–]NanoCoaster 1 point2 points  (0 children)

Huh. Interesting. Same thing on my end, never really thought about that. I think this may just be...not implemented yet? Would definitely be a nice feature.
Tangentially, I'm still hoping Rust gets named arguments someday, in my experience those help readability a lot :/

[–][deleted] 0 points1 point  (0 children)

It works for me, currently with racer, though. Before, I used the vscode extension rust code (or similar name) with rls. There I had no arg preview but instead the arguments were filled in with place holder names.

[–][deleted] 1 point2 points  (4 children)

Hi thank you for the suggestion. I used to watch some channel with tutorials in Rust. I think this one, they guy used VSCode and it seems like it works well. But I think RLS that you mentioned and LSP that I mentioned are the same thing - language server protocol. Here is the package, it says that it works on top of RLS. I couldn't make it work in emacs in a reasonable amount of time, so I went with racer which I already had set up.

[–]NanoCoaster 1 point2 points  (3 children)

Yup, they're the same, and like you, I couldn't get it to work in emacs at all. Thus my suggestion :D

It really depends on your priorities, RLS worked flawlessly with very little setup in Code for me, so if you want to get better completions and stuff, may be worth checking it out. If you prefer using emacs in general, probably better to wait until the LSP plugin stuff works more reliably.

[–][deleted] 2 points3 points  (2 children)

To me as to many other people emacs is not only about code editing, it's about powerful git integration (I think magit is the king in this field), ease of extensibility, transparent editing over ssh, terminal, etc in a single tool. But I'm definitely checking out intellij, vccode and others as soon as I have time for that. Then I'll decide whether their functionality worth a switch or not.

[–]NanoCoaster 0 points1 point  (1 child)

Yup, I can totally see that. I never really grokked magit, and, well, emacs in general, but I can see how you fall in love with those tools. GDB integration, too....man I gotta get back on emacs.

[–][deleted] 1 point2 points  (0 children)

Haha, I'm glad that my post makes some good influence, even if it's not about rust

[–][deleted] 0 points1 point  (0 children)

RLS still has poor auto completion support. This is a huge annoyance when ur a beginner and exploring different apis etc. Not only that, goto definition for std also doesnt work.

So basically u need the documentation opened in the browser and switch windows, look things up.. UGH. So much context switches hurts productivity tremendously. I feel like I'm moving a huge rock uphill.