Change over to using the definitions for mach-o types and defines to the
defines that are in "llvm/Support/MachO.h". This should allow ObjectFileMachO
and ObjectContainerUniversalMachO to be able to be cross compiled in Linux.
Also did some cleanup on the ASTType by renaming it to ClangASTType and
renaming the header file. Moved a lot of "AST * + opaque clang type *"
functionality from lldb_private::Type over into ClangASTType.
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@109046 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Expression/DWARFExpression.cpp b/source/Expression/DWARFExpression.cpp
index 839cf2e..20c97b2 100644
--- a/source/Expression/DWARFExpression.cpp
+++ b/source/Expression/DWARFExpression.cpp
@@ -24,6 +24,7 @@
#include "lldb/lldb-private-log.h"
+#include "lldb/Symbol/ClangASTType.h"
#include "lldb/Symbol/ClangASTContext.h"
#include "lldb/Symbol/Type.h"
@@ -2273,10 +2274,10 @@
}
else
{
- if (!Type::SetValueFromScalar(ast_context,
- clang_type,
- tmp.ResolveValue(exe_ctx, ast_context),
- new_value))
+ if (!ClangASTType::SetValueFromScalar (ast_context,
+ clang_type,
+ tmp.ResolveValue(exe_ctx, ast_context),
+ new_value))
{
if (error_ptr)
error_ptr->SetErrorStringWithFormat ("Couldn't extract a value from an integral type.\n");
@@ -2292,12 +2293,12 @@
{
lldb::AddressType address_type = (value_type == Value::eValueTypeLoadAddress ? eAddressTypeLoad : eAddressTypeHost);
lldb::addr_t addr = stack.back().GetScalar().ULongLong(LLDB_INVALID_ADDRESS);
- if (!Type::WriteToMemory (exe_ctx,
- ast_context,
- clang_type,
- addr,
- address_type,
- new_value))
+ if (!ClangASTType::WriteToMemory (ast_context,
+ clang_type,
+ exe_ctx,
+ addr,
+ address_type,
+ new_value))
{
if (error_ptr)
error_ptr->SetErrorStringWithFormat ("Failed to write value to memory at 0x%llx.\n", addr);