How LSP could have been better
Jonathan Blow criticized the performance and complexity of LSP in his talk at DevGAMM 2019 titled &quot;Preventing the Collapse of Civilization&quot; (timestamp 42m26s; <a href="https:&#x2F;&#x2F;youtu.be&#x2F;pW-SOdj4Kkk?t=2546" rel="nofollow noreferrer">https:&#x2F;&#x2F;youtu.be&#x2F;pW-SOdj4Kkk?t=2546</a>):<p>&gt; In the programming language world, there&#x27;s this thing called Language Server Protocol that is pretty much the worst thing I&#x27;ve ever heard of. There are proponents of this all over, building systems for it right now that are going to be living on your computer tomorrow, or maybe even today. As far as I can tell, it&#x27;s basically a more complicated, slower way to do libraries.<p>&gt; Say you&#x27;ve got an editor for some programming language and you want to be able to do stuff that we&#x27;ve been doing for decades already. For example, look up the declaration of an identifier by clicking on it, or have tooltips that say, &quot;What type is this value?&quot; Well, they say the way you should do that is—you know, you have your editor and then it&#x27;s a hassle to make plugins. This is the made-up problem. It&#x27;s a hassle to make plugins for all these different things. So in order to standardize, you&#x27;re going to run a server on your machine. Then your editor talks over a socket to the server, and the server talks back and gives you the answer. This approach has now turned your single program into a distributed system.<p>&gt; The flaw in this whole line of thinking, that none of these people seem to actually think about, is that there&#x27;s nothing special about looking up the location of an identifier in your code. That&#x27;s just an API, like we have all the time for everything. So the obvious next step, if you&#x27;re saying that we should architect our APIs like this, is to do this for other tasks. Now your editor, or whatever program, is going to be talking to multiple of these things. If you ever want to author anything for this, you now have to author and debug components of a distributed system where state is not located in any central place. We all know how fun that is, right?<p>&gt; But of course, libraries are not that simple. Libraries use other libraries. So what happens at that point is you&#x27;re running all these servers on your system, and who knows, some of them are going to go down and have to restart. People are synchronizing with each other—no, this is a disaster. And people are actively building this right now, while we&#x27;re spending all this time overcomplicating stuff that we used to be able to do in 1960.<p>(Transcript produced by asking GPT-4 to clean up the raw output from youtubetranscript.com: <a href="https:&#x2F;&#x2F;chat.openai.com&#x2F;share&#x2F;e1bc0e87-f79e-4958-98e7-b93c1b510a21" rel="nofollow noreferrer">https:&#x2F;&#x2F;chat.openai.com&#x2F;share&#x2F;e1bc0e87-f79e-4958-98e7-b93c1b...</a>)