jackguo380 / vim-lsp-cxx-highlight

Vim plugin for C/C++/ObjC semantic highlighting using cquery, ccls, or clangd
MIT License
337 stars 26 forks source link

No highlighting after opening existing Neovim Session file #83

Closed antoine-defrahan closed 2 years ago

antoine-defrahan commented 2 years ago

Describe the bug When opening an existing Neovim Session file, some (not all) tabs don't show the highlighting features. It is fixed by reloading the file (:e).

To Reproduce

Expected behavior Full highlighting features, as it works perfectly while not using Session files.

Screenshots Screenshot from 2022-03-03 12-15-58 Screenshot from 2022-03-03 12-16-47

Configuration

Log File:

Thu 03 Mar 2022 12:19:21 CET: lsp_cxx_hl beginning initialization...
Thu 03 Mar 2022 12:19:21 CET: vim-lsp not detected
Thu 03 Mar 2022 12:19:21 CET: LanguageClient-neovim not detected
Thu 03 Mar 2022 12:19:21 CET: coc.nvim successfully registered
Thu 03 Mar 2022 12:19:21 CET: nvim-lsp successfully registered
Thu 03 Mar 2022 12:19:21 CET: textprop nvim notify 108 symbols for View.hpp
Thu 03 Mar 2022 12:19:21 CET: hl_symbols (textprop nvim) highlighted 108 symbols in file View.hpp
Thu 03 Mar 2022 12:19:21 CET: operation hl_symbols (textprop nvim) View.hpp took   0.005115s to complete
Thu 03 Mar 2022 12:19:21 CET: textprop nvim notify 131 symbols for Subview.hpp
Thu 03 Mar 2022 12:19:21 CET: hl_symbols (textprop nvim) highlighted 131 symbols in file Subview.hpp
Thu 03 Mar 2022 12:19:21 CET: operation hl_symbols (textprop nvim) Subview.hpp took   0.005896s to complete
Thu 03 Mar 2022 12:19:21 CET: textprop nvim notify 43 symbols for MainWindow.hpp
Thu 03 Mar 2022 12:19:21 CET: hl_symbols (textprop nvim) highlighted 43 symbols in file MainWindow.hpp
Thu 03 Mar 2022 12:19:21 CET: operation hl_symbols (textprop nvim) MainWindow.hpp took   0.004194s to complete
Thu 03 Mar 2022 12:19:21 CET: textprop nvim notify 297 symbols for Subview.cpp
Thu 03 Mar 2022 12:19:21 CET: textprop nvim notify 266 symbols for MainWindow.cpp
Thu 03 Mar 2022 12:19:21 CET: stopped hl_symbols timer
Thu 03 Mar 2022 12:19:21 CET: hl_symbols (textprop nvim) highlighted 266 symbols in file MainWindow.cpp
Thu 03 Mar 2022 12:19:21 CET: operation hl_symbols (textprop nvim) MainWindow.cpp took   0.017920s to complete
Thu 03 Mar 2022 12:19:21 CET: textprop nvim notify 171 symbols for ClientController.cpp
Thu 03 Mar 2022 12:19:21 CET: hl_symbols (textprop nvim) highlighted 171 symbols in file ClientController.cpp
Thu 03 Mar 2022 12:19:21 CET: operation hl_symbols (textprop nvim) ClientController.cpp took   0.009065s to complete
Thu 03 Mar 2022 12:19:22 CET: textprop nvim notify 22 symbols for Main.cpp
Thu 03 Mar 2022 12:19:22 CET: hl_symbols (textprop nvim) highlighted 22 symbols in file Main.cpp
Thu 03 Mar 2022 12:19:22 CET: operation hl_symbols (textprop nvim) Main.cpp took   0.001142s to complete
Thu 03 Mar 2022 12:19:22 CET: textprop nvim notify 537 symbols for View.cpp
Thu 03 Mar 2022 12:19:22 CET: hl_symbols (textprop nvim) highlighted 537 symbols in file View.cpp
Thu 03 Mar 2022 12:19:22 CET: operation hl_symbols (textprop nvim) View.cpp took   0.018955s to complete
Thu 03 Mar 2022 12:19:22 CET: textprop nvim notify 47 symbols for ClientController.hpp
Thu 03 Mar 2022 12:19:22 CET: hl_symbols (textprop nvim) highlighted 47 symbols in file ClientController.hpp
Thu 03 Mar 2022 12:19:22 CET: operation hl_symbols (textprop nvim) ClientController.hpp took   0.002453s to complete
Thu 03 Mar 2022 12:19:50 CET: lsp_cxx_hl beginning initialization...
Thu 03 Mar 2022 12:19:50 CET: vim-lsp not detected
Thu 03 Mar 2022 12:19:50 CET: LanguageClient-neovim not detected
Thu 03 Mar 2022 12:19:50 CET: coc.nvim successfully registered
Thu 03 Mar 2022 12:19:50 CET: nvim-lsp successfully registered
Thu 03 Mar 2022 12:22:22 CET: lsp_cxx_hl beginning initialization...
Thu 03 Mar 2022 12:22:22 CET: vim-lsp not detected
Thu 03 Mar 2022 12:22:22 CET: LanguageClient-neovim not detected
Thu 03 Mar 2022 12:22:22 CET: coc.nvim successfully registered
Thu 03 Mar 2022 12:22:22 CET: nvim-lsp successfully registered

Thanks

antoine-defrahan commented 2 years ago

Appears to be a problem with the latest version of coc-clangd.