diff options
author | Sean Callanan <scallanan@apple.com> | 2012-04-11 21:48:13 +0000 |
---|---|---|
committer | Sean Callanan <scallanan@apple.com> | 2012-04-11 21:48:13 +0000 |
commit | 18a11e33ea4f19d17f84e2d9f375ef08c25ca85b (patch) | |
tree | bb442dd2cfee59acdcf261d1e2602d28a9d41517 /lldb | |
parent | d1411e1aa2f684dc7d8915dfa51e498e2339c64f (diff) | |
download | bcm5719-llvm-18a11e33ea4f19d17f84e2d9f375ef08c25ca85b.tar.gz bcm5719-llvm-18a11e33ea4f19d17f84e2d9f375ef08c25ca85b.zip |
Fixed a crash in Clang when a superclass of an
Objective-C class doesn't have a definition but
Clang tries to read through its protocols anyway.
llvm-svn: 154538
Diffstat (limited to 'lldb')
-rw-r--r-- | lldb/scripts/clang.check-definition-for-superclasses.diff | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/lldb/scripts/clang.check-definition-for-superclasses.diff b/lldb/scripts/clang.check-definition-for-superclasses.diff new file mode 100644 index 00000000000..566c518c197 --- /dev/null +++ b/lldb/scripts/clang.check-definition-for-superclasses.diff @@ -0,0 +1,15 @@ +Index: lib/AST/DeclObjC.cpp +=================================================================== +--- lib/AST/DeclObjC.cpp (revision 152265) ++++ lib/AST/DeclObjC.cpp (working copy) +@@ -330,6 +330,10 @@ + LoadExternalDefinition(); + + while (ClassDecl != NULL) { ++ // FIXME: Should make sure no callers ever do this. ++ if (!ClassDecl->hasDefinition()) ++ return 0; ++ + if ((MethodDecl = ClassDecl->getMethod(Sel, isInstance))) + return MethodDecl; + |