Skip to content

Commit 9c80a3d

Browse files
authored
Merge pull request #1990 from apple/lldb-Fix-few-easily-correctable-warnings
[lldb] Fix few easily correctable warnings
2 parents 0ac1051 + 590ecce commit 9c80a3d

File tree

3 files changed

+4
-12
lines changed

3 files changed

+4
-12
lines changed

lldb/source/Expression/REPL.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ static bool ReadCode(const std::string &path, std::string &code,
196196
const size_t max_size = code.max_size();
197197
if (file_size > max_size) {
198198
error_sp->Printf("file at path '%s' too large: "
199-
"file_size = %llu, max_size = %llu\n",
199+
"file_size = %zu, max_size = %zu\n",
200200
path.c_str(), file_size, max_size);
201201
return false;
202202
}

lldb/source/Plugins/TypeSystem/Swift/SwiftASTContext.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8342,14 +8342,6 @@ bool SwiftASTContext::CacheUserImports(SwiftASTContext &swift_ast_context,
83428342
Status &error) {
83438343
llvm::SmallString<1> m_description;
83448344

8345-
swift::ModuleDecl::ImportFilter import_filter {
8346-
swift::ModuleDecl::ImportFilterKind::Exported,
8347-
swift::ModuleDecl::ImportFilterKind::Default,
8348-
swift::ModuleDecl::ImportFilterKind::ImplementationOnly,
8349-
swift::ModuleDecl::ImportFilterKind::SPIAccessControl,
8350-
swift::ModuleDecl::ImportFilterKind::ShadowedByCrossImportOverlay
8351-
};
8352-
83538345
auto *persistent_expression_state =
83548346
sc.target_sp->GetSwiftPersistentExpressionState(exe_scope);
83558347

lldb/source/Target/SwiftLanguageRuntimeDynamicTypeResolution.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -965,7 +965,7 @@ llvm::Optional<uint64_t> SwiftLanguageRuntimeImpl::GetMemberVariableOffset(
965965
}
966966
if (offset) {
967967
LLDB_LOGF(GetLogIfAllCategoriesSet(LIBLLDB_LOG_TYPES),
968-
"[GetMemberVariableOffset] offset of %s is %d",
968+
"[GetMemberVariableOffset] offset of %s is %lld",
969969
member_name.str().c_str(), *offset);
970970
} else {
971971
LLDB_LOGF(GetLogIfAllCategoriesSet(LIBLLDB_LOG_TYPES),
@@ -2033,7 +2033,7 @@ bool SwiftLanguageRuntime::IsTaggedPointer(lldb::addr_t addr,
20332033
// Check whether this is a reference to an Objective-C object.
20342034
if ((addr & 1) == 1)
20352035
return true;
2036-
}
2036+
} break;
20372037
default:
20382038
break;
20392039
}
@@ -2098,7 +2098,7 @@ lldb::addr_t SwiftLanguageRuntime::FixupAddress(lldb::addr_t addr,
20982098
if (extra_deref)
20992099
return refd_addr;
21002100
}
2101-
}
2101+
} break;
21022102
default:
21032103
break;
21042104
}

0 commit comments

Comments
 (0)