4 ms·
> It took 2 years of work while sponsored by a real business With a team of 1.5 people. I personally wouldn't call that amount of effort "huge", but adjective
by matklad 3y ago
> It took 2 years of work while sponsored by a real business
With a team of 1.5 people. I personally wouldn't call that amount of effort "huge", but adjective definitions may vary. The important bit here is "couple of people over couple of years" is what it takes to get a decent IDE support from zero for a reasonable language, provided that the initial architecture is right.
> A short history of the rust-analyzer can be found
To clarify, I am the original author of that text, rust-analyzer, and IntelliJ Rust. To add a little more details, the reason why rust-analyzer was started in 2017, is that before that I had been working on IntelliJ Rust. By 2017, IntelliJ Rust was already in a good shape! And the success of IntelliJ Rust was the main reason why folks were willing to pay me money for working on rust-analyzer.
IntelliJ Rust was started on the 1st of September in 2015 (before RLS). No one used Rust at that point, not even for blockchain, and then I think it was impossible to predict with high level of confidence that Rust would be big. Even more so, I think both me and my manager at JetBrains were underestimating future Rust success at that time, as we were thinking mostly about relatively niche systems programming market, and didn't see that Rust would be a success as a general-purpose programming language with people doing web stuff in it (obviously, that niche would be occupied by Kotlin!).
But funding one intern to hack on an IDE for obscure language in St. Petersburg was not a significant expense for JetBrains. And, given that the plugin was well received by then nascent Rust community, it made sense to gamble and to just hire the intern to be a full time junior dev.
>So, yeah it takes little effort to get a basic IDE... that's where most languages (e.g. D, Nim) stop... the hard part is to get something that's really good.
This glosses over an important detail: rust-analyzer was playing catch up with RLS, the work on which started roughly a year after IntelliJ Rust, I think in august of 2016. Unlike rust-analyzer, RLS was a real effort by the rust project itself, but it just couldn't be good enough, because the underlying architecture was not suitable for IDEs. Adding more effort to RLS wouldn't have helped, it was necessary to build a different thing.
This I think is a bad equilibrium a lot of IDE efforts can get stuck in --- you really need to apply effort on top of the right architecture to not get stuck, but the knowledge of which architecture is right used to be very obscure.
- brabel 3y agoI see what you're saying... most people writing LSPs for new languages are doing it for the first time. They may spend a lot of time doing it and it will never be very good because they just don't really know what it takes. It's like that for any area of programming. What I am saying is that I think it's a huge effort exactly because of that: how many people have written an LSP before and are willing to do it for a new language? The fact that Jetbrains was actually behind rust-analyzer is actually news to me, despite having had exchanges with you before as a user of Rust IntelliJ for several years - I though you were "independent" of Jetbrains. That explains how it got so good so fast :D though I am very surprised a junior dev pulled it off... I suppose there was lots of "support" from the more experienced people, specially regarding the architecture, which I believe is what you're saying made it even possible? Anyway, great job on the Rust plugin, I've always used that and it was always solid... though now I am "migrating" (at least trying to) to Kate and using rust-analyzer via the LSP just because JetBrains has "deprecated" the Rust plugin in favour of the new Rust-specific IDE they're cooking up (as I'm sure you're aware). I also contributed to the emacs plugin (rustic) before but got a bit disillusioned with emacs performance :) small world. I guess Rust would've been successful (because of its own merits as a language) even if its IDE story was as bad as other new languages normally are (and eventually, because of many people having interest in it, the situation would improve fast), but maybe I'm wrong and the existence of rust-analyzer and RLS before that did actually "cause" the success... I don't think it's completely clear which is the case, and perhaps you're a bit biased in this story (no offense).
- matklad 3y ago>The fact that Jetbrains was actually behind rust-analyzer To clarify, I was not working at JetBrains when I started to work on rust-analyzer, so they are not _directly_ behind. They are very much indirectly behind though, as - JetBrains was funding a lot of educational projects for students of software engineering, such as myself. - JetBrains generally pioneered modern static analysis based IDEs: https://martinfowler.com/bliki/PostIntelliJ.html https://martinfowler.com/bliki/PostIntelliJ.html - Most of things I've learned about IDEs, I learned at JB, studying their open source tools - I was able to spend a year hacking on rust-analyzer for free due to my savings from the work at JetBrains - And, after those funds run out, I worked part time in the educational department of JB, teaching students algorithms, Python, and Rust > I suppose there was lots of "support" from the more experienced people, specially regarding the architecture, which I believe is what you're saying made it even possible? Not really, in a sense that I didn't have a dedicated mentor to check on me on a daily basis, but also such support is not really needed. You are writing a plugin, so the overall architecture is a given, and you just fill in the details. And most of the things you need you can learn from the docs and source code of existing plugins, and that also retroactively explains the overall architecture to you. So, by the time I started hacking on rust-analyzer, the core "throughput-vs-latency" tradeoff was clear to me, and, after taking an extra look at dart-analyzer, roslyn, and Swift libsyntax all pieces fell into place. It's a shame of course that there's no single "IDE book", and you really need to dig into the source and uncover the knowledge, but that's why `https://rust-analyzer.github.io/blog https://rust-analyzer.github.io/blog` exists! >I guess Rust would've been successful (because of its own merits as a language) even if its IDE story was as bad as other new languages normally are (and eventually, because of many people having interest in it, the situation would improve fast), but maybe I'm wrong and the existence of rust-analyzer and RLS before that did actually "cause" the success... Yeah, it's hard to untangle these! I would say these all were mutually reinforcing: fundamentals of language design screaming "this _could_ be big if it doesn't fail", people getting excited about Rust early on and hacking on the language and associated tooling, the tooling making it pleasant to actually use the language, people getting excited about using Rust to do stuff and increasing the size of the ecosystem (which directly defines the amount of funding available). The bottom turtle is maybe Graydon engineering the best language-design-and-implementation team in the world?