[cfe-commits] r58269 - /cfe/trunk/Driver/RewriteObjC.cpp
Steve Naroff
snaroff at apple.com
Mon Oct 27 13:54:44 PDT 2008
Author: snaroff
Date: Mon Oct 27 15:54:44 2008
New Revision: 58269
URL: http://llvm.org/viewvc/llvm-project?rev=58269&view=rev
Log:
Fix testsuite regression for "crash.m".
Modified:
cfe/trunk/Driver/RewriteObjC.cpp
Modified: cfe/trunk/Driver/RewriteObjC.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/Driver/RewriteObjC.cpp?rev=58269&r1=58268&r2=58269&view=diff
==============================================================================
--- cfe/trunk/Driver/RewriteObjC.cpp (original)
+++ cfe/trunk/Driver/RewriteObjC.cpp Mon Oct 27 15:54:44 2008
@@ -1259,7 +1259,8 @@
RewriteBlockCall(CE);
}
if (CastExpr *CE = dyn_cast<CastExpr>(S)) {
- RewriteCastExpr(CE);
+ if (CE->getLocStart().isValid())
+ RewriteCastExpr(CE);
}
#if 0
if (ImplicitCastExpr *ICE = dyn_cast<ImplicitCastExpr>(S)) {
@@ -2576,6 +2577,7 @@
Stmt *RewriteObjC::RewriteMessageExpr(ObjCMessageExpr *Exp) {
Stmt *ReplacingStmt = SynthMessageExpr(Exp);
+
// Now do the actual rewrite.
ReplaceStmt(Exp, ReplacingStmt);
More information about the cfe-commits
mailing list