mirror of
https://github.com/MaskRay/ccls.git
synced 2025-01-19 12:05:50 +00:00
nitpick fixing
This commit is contained in:
parent
4e153784f6
commit
63d2b5fa10
@ -995,9 +995,8 @@ void indexDeclaration(CXClientData client_data, const CXIdxDeclInfo* decl) {
|
||||
if (!db)
|
||||
return;
|
||||
|
||||
|
||||
// The language of this declaration
|
||||
LanguageId declLang = [decl] () {
|
||||
LanguageId decl_lang = [decl] () {
|
||||
switch (clang_getCursorLanguage(decl->cursor)) {
|
||||
case CXLanguage_C:
|
||||
return LanguageId::C;
|
||||
@ -1011,8 +1010,8 @@ void indexDeclaration(CXClientData client_data, const CXIdxDeclInfo* decl) {
|
||||
} ();
|
||||
|
||||
// Only update the file language if the new language is "greater" than the old
|
||||
if (declLang > db->language) {
|
||||
db->language = declLang;
|
||||
if (decl_lang > db->language) {
|
||||
db->language = decl_lang;
|
||||
}
|
||||
|
||||
NamespaceHelper* ns = ¶m->ns;
|
||||
|
@ -473,7 +473,6 @@ enum class LanguageId {
|
||||
Cpp = 2,
|
||||
ObjC = 3
|
||||
};
|
||||
|
||||
MAKE_REFLECT_TYPE_PROXY(LanguageId, std::underlying_type<LanguageId>::type);
|
||||
|
||||
struct IndexFile {
|
||||
|
Loading…
Reference in New Issue
Block a user