[Lldb-commits] [lldb] r168844 - /lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeVendor.cpp

Sean Callanan scallanan at apple.com
Wed Nov 28 16:50:56 PST 2012


Author: spyffe
Date: Wed Nov 28 18:50:56 2012
New Revision: 168844

URL: http://llvm.org/viewvc/llvm-project?rev=168844&view=rev
Log:
Don't return decorated (i.e., const or pointer)
versions of UnknownAnyTy for ObjectiveC value types.
<unknown type>* makes no sense and can cause the
parser to behave very oddly.

<rdar://problem/12518999>

Modified:
    lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeVendor.cpp

Modified: lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeVendor.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeVendor.cpp?rev=168844&r1=168843&r2=168844&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeVendor.cpp (original)
+++ lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeVendor.cpp Wed Nov 28 18:50:56 2012
@@ -422,6 +422,8 @@
                 clang::QualType target_type = BuildType(ast_ctx, type+1);
                 if (target_type.isNull())
                     return clang::QualType();
+                else if (target_type == ast_ctx.UnknownAnyTy)
+                    return ast_ctx.UnknownAnyTy;
                 else
                     return ast_ctx.getConstType(target_type);
             }
@@ -430,6 +432,8 @@
             clang::QualType target_type = BuildType(ast_ctx, type+1);
             if (target_type.isNull())
                 return clang::QualType();
+            else if (target_type == ast_ctx.UnknownAnyTy)
+                return ast_ctx.UnknownAnyTy;
             else
                 return ast_ctx.getPointerType(target_type);
         }





More information about the lldb-commits mailing list