Can you tell the server what language dialect to use?
SanderNotenbaert opened this issue · comments
I've got glsl-language-server set up on Neovim using require'lspconfig'.glslls.setup{}
. Working fine, but I'm getting diagnostics saying
'glslang: 'non-opaque uniforms outside a block': not allowed when using GLSL for Vulkan'
I'm not using Vulkan though. Is there a way to configure the language server for OpenGL Legacy?
I cannot verify right now, but try passing the --target-env=opengl
argument to glslls (double-check the exact names using the --help
flag)
Thanks for the suggestion! I've tried adding require("lspconfig").glslls.setup({ cmd = { "glslls", "--stdin", "--target-env=opengl" } })
in my Neovim setup. So far no change, as far as I can tell. LSP works, but catered to Vulkan it seems.
@SanderNotenbaert @nolanderc I created draft PR, that solved this problem for me.
But I don't have exp in c++, and might did smth wrong. Anyway I would appreciate if you tried to test my fixes and provided some feedback if fixes work for you as well.