4 ms·
> which is a show stopper for me since I've invested a lot into my neovim config. Level of confidence just 0.4, but, if you invested the same amount of time in
by matklad 4y ago
> which is a show stopper for me since I've invested a lot into my neovim config.
Level of confidence just 0.4, but, if you invested the same amount of time into IntelliJ platform, you might have got more out of it. The “advanced semantic features” rabbit whole is as deep as “advanced vim”, it’s just less popular :-)
- davidatbu 4y agoIf you can share more about your reasoning here, or share blog posts etc (especially if they compare/contrast with the LSP/vim experience), I'd be very grateful! I've been looking everywhere for evidence of the value-add of IDEs as compared to my neovim_plugins+LSP setup, but haven't found anything that convinced me to do the investment.
- matklad 4y agoI've wrote a bit about this in https://matklad.github.io/2020/11/11/yde.html https://matklad.github.io/2020/11/11/yde.html Some specific things which IntelliJ brings to me: 1. Rich refactors -- things like "change signature" are a huge time saver in big codebases. LSP still can't do interactive refactors which require user input. 2. Structural Search Replace -- you can grep and sed sourcecode by matching on AST and semantic information. 3. Significantly more polished basic features. When I search for a thing in VS Code, I get a flat list of 20 occurrences. When I search for a thing in IntelliJ, I have 20 occurrences, but I immediately see that 12 come from tests, and, among the remaining 8, I can clearly identify 2 write and 6 reads, and it's writes I care about. 4. Significantly better integration with language specific tooling. When I want to run a custom command in VS Code, I open terminal and type `cargo run --package foo --bin bar`. In IntelliJ, I press a shortcut and get auto-completion not only for general cargo command, but for project specific things as well (eg, IntelliJ knows that `foo` package exists and completes that). 5. Local history -- rather than maintaining a hard-to-visualize and unintuitive undo-tree, IntelliJ transparently remembers all transient version of a file and shows you a fine-grained "git log" with diffs and such. 6. Merge tool that understands semantics of the language and can resolve a lot more conflicts automatically (though, to be fair, the actual Git interface still is not as good as magit) 7. A lot of polished "small things". IntelliJ helps a lot with adding punctuation, placing the cursor in the right position and doing other small editing tasks. Subjectively, it significantly reduces the cognitive load for just typing the code in. I guess, the overall thing here is not so much as some big, flashy things, but rather than a myriad of small, polished details. Like vim has a dedicated command/keysequence for anything, IntelliJ exploits any semantic information it can get from the sourcecode to be helpful.
- pie_flavor 4y agoIf you weren't aware, VS Code recently gained (5). (Though JB's is still better.)
- matklad 4y agoIndeed, I wasn't, thanks!
- davidatbu 4y agoDidn't realize I was talking to the person who worked both on IntelliJ Rust and rust-analyzer! This is the best case I've ever heard for IDEs. Thank you!! 1 and 3 seem to me to require extensions/improvements to the LSP protocol. 2, and 6 seem like one could build them off of treesitter (but I don't think anyone has as of yet). 5 seems already implemented in a vim plugin[0]. Thanks for 4 and 7 (the "myriad of small, polished details") also, I feel like I have to spend a week using an IDE to get a feel for them. [0] https://github.com/dinhhuy258/vim-local-history https://github.com/dinhhuy258/vim-local-history