On Windows, my lsp doesnt work if I dont have visual studio installed. I used to only have a hdd and befor trying nvim I was using Visual Studio (the purple one) for c/c++ programming. The config worked fine, but when I tried, the same config, on my notebook running Windows it didnt work? I keept slamming my head against the table for a few hours and SOMEHOW I discovered it was because I had Visual Studio installed on my main pc. I installed Visual Studio on the notebook and the LSP worked. Now I have linux on my notebook and I use the same config; works fine. Does someone know why that happens? The path for gcc/g++/clang is set, I can compile from the terminal, and as I stated, the problem is not on the config, since THE SAME CONFIG works when Visual Studio is installed.
Just to complement, I use mason and lspconfig, gcc/g++/clang were installed via msys2.
On Windows, my lsp doesnt work if I dont have visual studio installed. I used to only have a hdd and befor trying nvim I was using Visual Studio (the purple one) for c/c++ programming. The config worked fine, but when I tried, the same config, on my notebook running Windows it didnt work? I keept slamming my head against the table for a few hours and SOMEHOW I discovered it was because I had Visual Studio installed on my main pc. I installed Visual Studio on the notebook and the LSP worked. Now I have linux on my notebook and I use the same config; works fine. Does someone know why that happens? The path for gcc/g++/clang is set, I can compile from the terminal, and as I stated, the problem is not on the config, since THE SAME CONFIG works when Visual Studio is installed.
Just to complement, I use mason and lspconfig, gcc/g++/clang were installed via msys2.
Share Improve this question asked Mar 3 at 4:26 EnderMegaEnderMega 3431 gold badge2 silver badges13 bronze badges1 Answer
Reset to default 0Which C++ language server are you using? The language server is different from the compiler. None of gcc/g++/clang provides a language server. Likely the toolchain installed together with Visual Studio happened to include a language server, e.g., clangd.
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745109703a4611773.html
评论列表(0条)