[cfe-commits] r44026 - /cfe/trunk/Sema/SemaExpr.cpp
Fariborz Jahanian
fjahanian at apple.com
Mon Nov 12 12:20:37 PST 2007
Author: fjahanian
Date: Mon Nov 12 14:20:37 2007
New Revision: 44026
URL: http://llvm.org/viewvc/llvm-project?rev=44026&view=rev
Log:
Minor twik for when there is no super class and 'super' is errornously used.
Modified:
cfe/trunk/Sema/SemaExpr.cpp
Modified: cfe/trunk/Sema/SemaExpr.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/Sema/SemaExpr.cpp?rev=44026&r1=44025&r2=44026&view=diff
==============================================================================
--- cfe/trunk/Sema/SemaExpr.cpp (original)
+++ cfe/trunk/Sema/SemaExpr.cpp Mon Nov 12 14:20:37 2007
@@ -2070,7 +2070,7 @@
ObjcInterfaceDecl* ClassDecl = 0;
if (!strcmp(receiverName->getName(), "super") && CurMethodDecl) {
ClassDecl = CurMethodDecl->getClassInterface()->getSuperClass();
- if (CurMethodDecl->isInstance()) {
+ if (ClassDecl && CurMethodDecl->isInstance()) {
IdentifierInfo &II = Context.Idents.get("self");
ExprResult ReceiverExpr = ActOnIdentifierExpr(S, lbrac, II,
false);
More information about the cfe-commits
mailing list