nitpick fixing

This commit is contained in:
topisani 2017-11-30 23:09:29 +01:00 committed by Jacob Dufault
parent 4e153784f6
commit 63d2b5fa10
2 changed files with 3 additions and 5 deletions

View File

@ -995,9 +995,8 @@ void indexDeclaration(CXClientData client_data, const CXIdxDeclInfo* decl) {
if (!db) if (!db)
return; return;
// The language of this declaration // The language of this declaration
LanguageId declLang = [decl] () { LanguageId decl_lang = [decl] () {
switch (clang_getCursorLanguage(decl->cursor)) { switch (clang_getCursorLanguage(decl->cursor)) {
case CXLanguage_C: case CXLanguage_C:
return LanguageId::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 // Only update the file language if the new language is "greater" than the old
if (declLang > db->language) { if (decl_lang > db->language) {
db->language = declLang; db->language = decl_lang;
} }
NamespaceHelper* ns = &param->ns; NamespaceHelper* ns = &param->ns;

View File

@ -473,7 +473,6 @@ enum class LanguageId {
Cpp = 2, Cpp = 2,
ObjC = 3 ObjC = 3
}; };
MAKE_REFLECT_TYPE_PROXY(LanguageId, std::underlying_type<LanguageId>::type); MAKE_REFLECT_TYPE_PROXY(LanguageId, std::underlying_type<LanguageId>::type);
struct IndexFile { struct IndexFile {