fix(clangd): languageIds for objc, cuda #4322

Problem:
clangd currently receives incorrect languageId
values for objc, objcpp and cuda.

Solution:
Update the filetype to languageId mapping to send
the values expected by the language server.

ref https://code.visualstudio.com/docs/languages/identifiers
This commit is contained in:
Amitayas Banerjee 2026-02-24 02:40:07 +05:30 committed by GitHub
parent 5a855bcfec
commit cfc12beefe
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -74,6 +74,10 @@ return {
'configure.ac', -- AutoTools
'.git',
},
get_language_id = function(_, ftype)
local t = { objc = 'objective-c', objcpp = 'objective-cpp', cuda = 'cuda-cpp' }
return t[ftype] or ftype
end,
capabilities = {
textDocument = {
completion = {