Merged Eli Friedman's linux build changes where he added Makefile files that
enabled LLVM make style building and made this compile LLDB on Mac OS X. We
can now iterate on this to make the build work on both linux and macosx.
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@108009 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Symbol/ClangASTContext.cpp b/source/Symbol/ClangASTContext.cpp
index b9670d4..6bb91ea 100644
--- a/source/Symbol/ClangASTContext.cpp
+++ b/source/Symbol/ClangASTContext.cpp
@@ -904,12 +904,6 @@
{
if (class_clang_type)
{
- ASTContext *ast_context = getASTContext();
- IdentifierTable *identifier_table = getIdentifierTable();
-
- assert (ast_context != NULL);
- assert (identifier_table != NULL);
-
Type *clang_type = QualType::getFromOpaquePtr(class_clang_type).getTypePtr();
if (clang_type)
{
@@ -1157,8 +1151,6 @@
++child_idx;
}
}
- const unsigned num_fields = record_layout.getFieldCount();
-
// Make sure index is in range...
uint32_t field_idx = 0;
RecordDecl::field_iterator field, field_end;
@@ -1173,7 +1165,7 @@
// Figure out the type byte size (field_type_info.first) and
// alignment (field_type_info.second) from the AST context.
std::pair<uint64_t, unsigned> field_type_info = ast_context->getTypeInfo(field->getType());
- assert(field_idx < num_fields);
+ assert(field_idx < record_layout.getFieldCount());
child_byte_size = field_type_info.first / 8;