[cfe-commits] r70978 - /cfe/branches/Apple/objective-rewrite/tools/clang/Driver/RewriteObjC.cpp

Steve Naroff snaroff at apple.com
Tue May 5 09:13:14 PDT 2009


Author: snaroff
Date: Tue May  5 11:13:10 2009
New Revision: 70978

URL: http://llvm.org/viewvc/llvm-project?rev=70978&view=rev
Log:
Fix <rdar://problem/6201430> clang ObjC rewriter: if "{" is next to name of superclass in @interface, IMPL class name is incorrect.

Modified:
    cfe/branches/Apple/objective-rewrite/tools/clang/Driver/RewriteObjC.cpp

Modified: cfe/branches/Apple/objective-rewrite/tools/clang/Driver/RewriteObjC.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/branches/Apple/objective-rewrite/tools/clang/Driver/RewriteObjC.cpp?rev=70978&r1=70977&r2=70978&view=diff

==============================================================================
--- cfe/branches/Apple/objective-rewrite/tools/clang/Driver/RewriteObjC.cpp (original)
+++ cfe/branches/Apple/objective-rewrite/tools/clang/Driver/RewriteObjC.cpp Tue May  5 11:13:10 2009
@@ -2711,7 +2711,7 @@
       ReplaceText(LocStart, endHeader-startBuf, Result.c_str(), Result.size());
     } else {
       // rewrite the original header *without* disturbing the '{'
-      ReplaceText(LocStart, cursor-startBuf-1, Result.c_str(), Result.size());
+      ReplaceText(LocStart, cursor-startBuf, Result.c_str(), Result.size());
     }
     if (RCDecl && ObjCSynthesizedStructs.count(RCDecl)) {
       Result = "\n    struct ";





More information about the cfe-commits mailing list