Added support for the fragile ivars provided by
Apple's Objective-C 2.0 runtime.  They are enabled
if the Objective-C runtime has the proper version.


git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@123694 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Expression/ClangExpressionDeclMap.cpp b/source/Expression/ClangExpressionDeclMap.cpp
index 08468fa..f996242 100644
--- a/source/Expression/ClangExpressionDeclMap.cpp
+++ b/source/Expression/ClangExpressionDeclMap.cpp
@@ -452,6 +452,36 @@
     return true;
 }
 
+bool 
+ClangExpressionDeclMap::GetSymbolAddress
+(
+    const ConstString &name,
+    uint64_t &ptr
+)
+{
+    assert (m_parser_vars.get());
+    
+    // Back out in all cases where we're not fully initialized
+    if (m_parser_vars->m_exe_ctx->target == NULL)
+        return false;
+    
+    SymbolContextList sc_list;
+    
+    m_parser_vars->m_exe_ctx->target->GetImages().FindSymbolsWithNameAndType(name, lldb::eSymbolTypeAny, sc_list);
+    
+    if (!sc_list.GetSize())
+        return false;
+    
+    SymbolContext sym_ctx;
+    sc_list.GetContextAtIndex(0, sym_ctx);
+    
+    const Address *sym_address = &sym_ctx.symbol->GetAddressRangeRef().GetBaseAddress();
+    
+    ptr = sym_address->GetLoadAddress (m_parser_vars->m_exe_ctx->target);
+    
+    return true;
+}
+
 // Interface for CommandObjectExpression
 
 bool