
Rust Analyzer: Next few years - m-sopanen
https://rust-analyzer.github.io/blog/2020/05/18/next-few-years.html
======
sjroot
If you haven’t yet used rust-analyzer, immediately go and try it out. The
developer experience is much better than RLS, particularly for larger
projects.

One question I’ve had for some time: what exactly is the relationship between
Ferrous Systems and the Rust core team? The most important part of this
article - the call for sponsors - calls out the former, but I would think
Mozilla would also be greatly motivated to sponsor this work. (If they haven’t
already?)

~~~
GolDDranks
Ferrous Systems is a private consulting company that specialises on Rust and
sponsors some community projects such as Rust-Analyzer. I don't think the
company has any "official" relationship with Rust governance. However, Florian
Gilcher and Aleksey Kladov who both work at Ferrous Systems are active
community members and also members in some Rust teams.

It's generally thought in the Rust community that the community benefits from
diversifying the pool of stakeholders and also commercial players. Rust
doesn't want to identify too hard as "Mozilla's language".

Edit: Forgot to mention: There isn't currently any legal body such as "Rust
foundation" so it's hard for the Rust project itself financially sponsor this
kind of project. It's mostly either Mozilla or then some "third party" player.

~~~
eminence32
On the topic of a "Rust Foundation", there a semi-recent blog post from one of
the rust core members on this:

[http://smallcultfollowing.com/babysteps/blog/2020/01/09/towa...](http://smallcultfollowing.com/babysteps/blog/2020/01/09/towards-
a-rust-foundation/)

------
nahuel0x
Using a Prolog implementation behind Rust Analyzer is very interesting, here
is the post announcing it:
[http://smallcultfollowing.com/babysteps/blog/2017/01/26/lowe...](http://smallcultfollowing.com/babysteps/blog/2017/01/26/lowering-
rust-traits-to-logic/) and more info here: [https://github.com/rust-
lang/chalk](https://github.com/rust-lang/chalk)

~~~
todd8
My reading of the linked references indicate that the system is _not_ using
Prolog or even Horn clauses. They are using a logic inference engine, but it
isn't a Prolog system.

~~~
nahuel0x
is a Prolog derivative with FOHH clauses, first post says it.

------
cdbattags
This is the future of all systems/OS programming in my opinion.

My other goals for 2030:

\- RISC-V ubiquity

\- RedoxOS on all major archs

\- Linux kernel maintenance shifting to at least 25% Rust code

Rust Analyzer is one of the biggest pieces that I think will get us there as
far as compile times and beating out C++ ubiquity that is already in this
space.

------
wrs
"A quick one-to-two-year hack" ... that is an impressive attitude. Respect.

------
amelius
Is there a standard for "IDE backends", and can I plug one into my favorite
editor, Vim?

~~~
gameswithgo
Yes, it uses the language server protocol:
[https://microsoft.github.io/language-server-
protocol/](https://microsoft.github.io/language-server-protocol/)

The rust-analyzer docs show how to wire it up to VIM a few different ways:
[https://rust-analyzer.github.io/manual.html#installation](https://rust-
analyzer.github.io/manual.html#installation)

~~~
habitue
It's important to point out that rust-analyzer uses some bleeding edge
features of the protocol, so sometimes certain things won't work as well in
editors other than vscode. That being said, I believe the rust-analyzer author
has indicated that he would fix that up to use more standard features if rust-
analyzer becomes the officially recommended IDE backend.

------
mazeltovvv
If you’re on vscode it is probably not the moment to switch to rust analyzer.
It doesn’t work that well compared to rls. It gets tripped up easily and stops
working if your code has bugs. It also doesn’t format on save.

~~~
weiming
Anecdotally/to add a counterpoint, my experience using RA over the last few
weeks has been very very positive.

~~~
throwaway894345
Mine as well.

------
Avi-D-coder
Why is GAT struck out?

~~~
steveklabnik
I read it as a joke; chalk is necessary but not sufficient for the language to
gain GATs.

~~~
Avi-D-coder
What other major things are needed?

~~~
steveklabnik
In my understanding, Chalk's immediate goal is to be able to reproduce the
existing trait system. Achieving that goal does not mean that GATs just
automatically happen; they'll need to be implemented in Chalk, and then all
the other polish work that happens with new major features needs to happen.
There's a ton of work other than "chalk exists."

~~~
Avi-D-coder
I believe GATs are at least somewhat supported in chalk
[https://github.com/rust-lang/chalk/issues/116](https://github.com/rust-
lang/chalk/issues/116)

------
jonnypotty
If anyone uses this and can be bothered to explain what would be the insentive
to move from using cargo on the command line and sublime text to this?

~~~
thomasfoster96
You can use rust-analyzer from within Sublime Text: [https://rust-
analyzer.github.io/manual.html#sublime-text-3](https://rust-
analyzer.github.io/manual.html#sublime-text-3)

If you’re using Sublime Text 3, it’s essentially an alternative to
RustEnhanced[0].

[0] [https://github.com/rust-lang/rust-enhanced](https://github.com/rust-
lang/rust-enhanced)

~~~
urschrei
It's absolutely not an alternative to RustEnhanced. Sublime-LSP + Rust-
Analyzer complement RustEnhanced, adding Language Server functionality. They
don't conflict in any way.

Source: me, a contributor to both RustEnhanced and Sublime-LSP

~~~
thomasfoster96
You’re right, I was mistaken (and too late to edit my comment).

Out of interest, is there a page anywhere explaining the difference between
RustEnhanced and Sublime-LSP + Rust Analyzer? I’ve got both installed, but
when I enable Sublime-LSP + RustAnalyzer the experience and functionality is
different enough that I assumed it was overriding RustEnhanced.

