Skip to content

Commit ef4536c

Browse files
Fix warnings from clang build on macOS.
Reviewers: lldb-commits Subscribers: lldb-commits Differential Revision: https://reviews.llvm.org/D31279 llvm-svn: 298585
1 parent 93683b6 commit ef4536c

File tree

5 files changed

+5
-2
lines changed

5 files changed

+5
-2
lines changed

lldb/source/Expression/LLVMUserExpression.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,10 @@ LLVMUserExpression::LLVMUserExpression(ExecutionContextScope &exe_scope,
4949
const EvaluateExpressionOptions &options)
5050
: UserExpression(exe_scope, expr, prefix, language, desired_type, options),
5151
m_stack_frame_bottom(LLDB_INVALID_ADDRESS),
52+
m_stack_frame_top(LLDB_INVALID_ADDRESS),
5253
m_allow_cxx(false),
5354
m_allow_objc(false),
54-
m_stack_frame_top(LLDB_INVALID_ADDRESS), m_transformed_text(),
55+
m_transformed_text(),
5556
m_execution_unit_sp(), m_materializer_ap(), m_jit_module_wp(),
5657
m_enforce_valid_object(true), m_in_cplusplus_method(false),
5758
m_in_objectivec_method(false), m_in_static_method(false),

lldb/source/Host/common/Symbols.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ static bool FileAtPathContainsArchAndUUID(const FileSpec &file_fspec,
5555
ModuleSpec spec;
5656
for (size_t i = 0; i < module_specs.GetSize(); ++i) {
5757
bool got_spec = module_specs.GetModuleSpecAtIndex(i, spec);
58+
UNUSED_IF_ASSERT_DISABLED(got_spec);
5859
assert(got_spec);
5960
if ((uuid == NULL || (spec.GetUUIDPtr() && spec.GetUUID() == *uuid)) &&
6061
(arch == NULL || (spec.GetArchitecturePtr() &&

lldb/source/Host/macosx/Symbols.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -270,6 +270,7 @@ FileSpec Symbols::FindSymbolFileInBundle(const FileSpec &dsym_bundle_fspec,
270270
ModuleSpec spec;
271271
for (size_t i = 0; i < module_specs.GetSize(); ++i) {
272272
bool got_spec = module_specs.GetModuleSpecAtIndex(i, spec);
273+
UNUSED_IF_ASSERT_DISABLED(got_spec);
273274
assert(got_spec);
274275
if ((uuid == NULL ||
275276
(spec.GetUUIDPtr() && spec.GetUUID() == *uuid)) &&

lldb/source/Plugins/Process/Utility/DynamicRegisterInfo.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,7 @@ DynamicRegisterInfo::SetRegisterInfo(const StructuredData::Dictionary &dict,
281281
// Swap "dwarf_opcode_string" over into "opcode_extractor"
282282
opcode_extractor.GetStringRef().swap(dwarf_opcode_string);
283283
uint32_t ret_val = opcode_extractor.GetHexBytesAvail(dwarf_opcode_bytes);
284+
UNUSED_IF_ASSERT_DISABLED(ret_val);
284285
assert(ret_val == reg_info.dynamic_size_dwarf_len);
285286

286287
for (j = 0; j < reg_info.dynamic_size_dwarf_len; ++j)

lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerCommon.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -771,7 +771,6 @@ GDBRemoteCommunicationServerCommon::Handle_vFile_MD5(
771771
std::string path;
772772
packet.GetHexByteString(path);
773773
if (!path.empty()) {
774-
uint64_t a, b;
775774
StreamGDBRemote response;
776775
auto Result = llvm::sys::fs::md5_contents(path);
777776
if (!Result) {

0 commit comments

Comments
 (0)