3 ms·
Don't get me wrong, a lot of these problems aren't really Emacs's fault. Jetbrains puts a lot of money and effort into its IDEs. If some commercial or nonprofit
by jonnycomputer 6y ago
Don't get me wrong, a lot of these problems aren't really Emacs's fault. Jetbrains puts a lot of money and effort into its IDEs. If some commercial or nonprofit entity was actually committed to developing and maintaining elisp packages providing superb language support, then Emacs would have it.
Maybe language support will get better with LSP; anyone know how that is going in the emacs world?
- justinlilly 6y agoI use lsp. It's not as good as pycharm, et al, but it's good.
- mplanchard 6y agoI’ve used lsp-mode for python, go, typescript, rust, and haskell. Had to do a little bit of fiddling with settings and trying different servers to get something performant for a very large python codebase, and I did some more fiddling to adjust some delays and whatnot to get everything feeling snappy with the way I edit text. I still find that it feels faster on Linux than on Mac, but I don’t use the latter much anymore anyway. My general impression of lsp-mode is that it’s great, once you get the settings the way you like them. Errors and warnings are nicely integrated into flycheck, and the lsp-ui package provides some niceties like automatically showing function signatures, showing error information inline with the code, and so on.
- jonnycomputer 6y agoIt does actually sound like things have improved since when I started moving away from primary development in emacs circa 2016-17. It might be time to revisit my config file. I still end up coding in emacs a lot of the time.
- mplanchard 6y agoEmacs 27 helped a ton with language server performance, I believe because they reworked the JSON parser to be quite a lot faster. There’s also a “native-comp” feature that’s available experimentally in 28, which does native compilation of most of the .el files in emacs. I’ve played with it a bit and it does seem like a significant speed up across the board. Definitely a lot of exciting things happening!
- TeMPOraL 6y agoYup, Emacs switched to Jansson[0] for JSON parsing. Since LSP uses JSON a lot, this means big performance improvements there. Also seconding "native-comp" branch. It's technically experimental, but in practice it's pretty much stable. I've been running on it daily for the past 6+ months, with zero problems. The way it works is, it uses GCC (libgccjit) to compile Emacs Lisp down to native (vs. the EL bytecode Emacs normally uses) on the fly, and then replaces the byte-compiled function with its native-compiled version. It does it transparently, across all elisp code you use - built-in and thrid party alike. What you get is a huge performance boost, and occasional messages that something gets compiled, when you run some new elisp for the first time. -- [0] - https://digip.org/jansson/ https://digip.org/jansson/
- neutronicus 6y agoIt doesn't really work for C++ Like it can, but not on our codebase
- amake 6y agoI use Emacs professionally for Ruby development and LSP (Solargraph) is a huge part of what makes it work smoothly. I also do a lot of hobby Flutter/Dart development and the same is true there. Languages that I’ve tried to work with this way but failed include Java, Kotlin, Swift, and C#. But I could see any of them working great if the LSP implementation was robust enough.
- OrderlyTiamat 6y agoI use lsp for python and c++. It's usually good, but lsp will sometimes have the clang seever crash repeatedly, which can usually only be fixed by restarting emacs. I do debugging with gdb, which is rather nice actually (you can easily set breakpoints and it will show the pointer walking through all the files), but even there there are some rough edges (the in/output buffer will show up on all frames for example, and will pop up, closing the gdb buffer itself) All in all this is a rather good setup imo, with a little polishing I'd never have to use anything else I think. Maybe I'll try out Doom again, it might be that my config is contributing to the unstableness...
- hvis 6y agoIf Clang server crashes, surely that means some bug in it was triggered? lsp-mode only converses with it over JSON, after all. Clang's developers might appreciate the corresponding bug reports.
- sokoloff 6y agoJetBrains has a straightforward way to pay for all that development and polishing time, which is lacking (due to sound but foundational reasons) on the emacs side.
- legends2k 6y agoI use LSP for Rust (rust-analyzer) and C++ (ccls) and I would say the experience is pretty good. For C++ projects I generate a compile_commands.json (Ninja, CMake or meson should help) and after that it's smooth sailing. I get contextual auto complete suggestions (yasnippet and complete even fills function arg placeholders), definition lookups, find all references, alternate between header and source, etc.