I enabled some extra warnings for hidden local variables and for hidden
virtual functions and caught some things and did some general code cleanup.
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@108299 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Symbol/ClangASTContext.cpp b/source/Symbol/ClangASTContext.cpp
index 6bb91ea..153ae81 100644
--- a/source/Symbol/ClangASTContext.cpp
+++ b/source/Symbol/ClangASTContext.cpp
@@ -1493,7 +1493,6 @@
decl_name.getAsOpaquePtr(),
paths))
{
- uint32_t child_idx;
CXXBasePaths::const_paths_iterator path, path_end = paths.end();
for (path = paths.begin(); path != path_end; ++path)
{
diff --git a/source/Symbol/DWARFCallFrameInfo.cpp b/source/Symbol/DWARFCallFrameInfo.cpp
index 0b37aba..4b6d19f 100644
--- a/source/Symbol/DWARFCallFrameInfo.cpp
+++ b/source/Symbol/DWARFCallFrameInfo.cpp
@@ -664,8 +664,7 @@
while (m_cfi_data.ValidOffsetForDataOfSize(offset, 8))
{
const dw_offset_t curr_offset = offset;
- const uint32_t length = m_cfi_data.GetU32(&offset);
- const dw_offset_t next_offset = offset + length;
+ const dw_offset_t next_offset = offset + m_cfi_data.GetU32(&offset);
const dw_offset_t cie_id = m_cfi_data.GetU32(&offset);
bool is_fde = for_eh_frame ? cie_id != 0 : cie_id != UINT32_MAX;
diff --git a/source/Symbol/Type.cpp b/source/Symbol/Type.cpp
index a66e12a..41336a7 100644
--- a/source/Symbol/Type.cpp
+++ b/source/Symbol/Type.cpp
@@ -399,7 +399,7 @@
else
buf.resize (256);
- lldb_private::DataExtractor data(buf.data(), buf.size(), exe_ctx->process->GetByteOrder(), 4);
+ lldb_private::DataExtractor cstr_data(buf.data(), buf.size(), exe_ctx->process->GetByteOrder(), 4);
buf.back() = '\0';
size_t bytes_read;
size_t total_cstr_len = 0;
@@ -411,7 +411,7 @@
break;
if (total_cstr_len == 0)
s->PutCString (" \"");
- data.Dump(s, 0, lldb::eFormatChar, 1, len, UINT32_MAX, LLDB_INVALID_ADDRESS, 0, 0);
+ cstr_data.Dump(s, 0, lldb::eFormatChar, 1, len, UINT32_MAX, LLDB_INVALID_ADDRESS, 0, 0);
total_cstr_len += len;
if (len < buf.size())
break;