[Lldb-commits] [lldb] r121070 - in /lldb/trunk/source: Expression/IRForTarget.cpp Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp Symbol/ClangASTContext.cpp

Sean Callanan scallanan at apple.com
Mon Dec 6 15:53:20 PST 2010


Author: spyffe
Date: Mon Dec  6 17:53:20 2010
New Revision: 121070

URL: http://llvm.org/viewvc/llvm-project?rev=121070&view=rev
Log:
Fixes to make id work as well as well as fix minor errors
when calling built-ins.

Modified:
    lldb/trunk/source/Expression/IRForTarget.cpp
    lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
    lldb/trunk/source/Symbol/ClangASTContext.cpp

Modified: lldb/trunk/source/Expression/IRForTarget.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Expression/IRForTarget.cpp?rev=121070&r1=121069&r2=121070&view=diff
==============================================================================
--- lldb/trunk/source/Expression/IRForTarget.cpp (original)
+++ lldb/trunk/source/Expression/IRForTarget.cpp Mon Dec  6 17:53:20 2010
@@ -964,6 +964,10 @@
             if (!fun)
                 return false;
         }
+        else if (const_expr && const_expr->getOpcode() == Instruction::IntToPtr)
+        {
+            return true; // already resolved
+        }
         else
         {
             return false;

Modified: lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp?rev=121070&r1=121069&r2=121070&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp (original)
+++ lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp Mon Dec  6 17:53:20 2010
@@ -2933,7 +2933,7 @@
                         }
                         else if (type_name_const_str == g_objc_type_name_selector)
                         {
-                            clang_type = ast.CreatePointerType(ast.GetBuiltInType_objc_selector());
+                            clang_type = ast.GetBuiltInType_objc_selector();
                             resolve_state = Type::eResolveStateFull;
                         }
                     }

Modified: lldb/trunk/source/Symbol/ClangASTContext.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Symbol/ClangASTContext.cpp?rev=121070&r1=121069&r2=121070&view=diff
==============================================================================
--- lldb/trunk/source/Symbol/ClangASTContext.cpp (original)
+++ lldb/trunk/source/Symbol/ClangASTContext.cpp Mon Dec  6 17:53:20 2010
@@ -677,7 +677,7 @@
 clang_type_t
 ClangASTContext::GetBuiltInType_objc_id()
 {
-    return getASTContext()->ObjCBuiltinIdTy.getAsOpaquePtr();
+    return getASTContext()->getPointerType(getASTContext()->ObjCBuiltinIdTy).getAsOpaquePtr();
 }
 
 clang_type_t
@@ -689,7 +689,7 @@
 clang_type_t
 ClangASTContext::GetBuiltInType_objc_selector()
 {
-    return getASTContext()->ObjCBuiltinSelTy.getAsOpaquePtr();
+    return getASTContext()->getPointerType(getASTContext()->ObjCBuiltinSelTy).getAsOpaquePtr();
 }
 
 clang_type_t





More information about the lldb-commits mailing list