From: Steve Naroff Date: Tue, 21 Oct 2008 13:37:27 +0000 (+0000) Subject: Fix confused in some way by embedded /* */ comments. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=94ac21ea70f22d695c2a406a07d121d16e505a1b;p=clang Fix confused in some way by embedded /* */ comments. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@57903 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/Driver/RewriteObjC.cpp b/Driver/RewriteObjC.cpp index 18afbaa685..14f6ade591 100644 --- a/Driver/RewriteObjC.cpp +++ b/Driver/RewriteObjC.cpp @@ -595,8 +595,8 @@ void RewriteObjC::RewriteMethodDeclaration(ObjCMethodDecl *Method) { SourceLocation LocEnd = Method->getLocEnd(); if (SM->getLineNumber(LocEnd) > SM->getLineNumber(LocStart)) { - InsertText(LocStart, "/* ", 3); - ReplaceText(LocEnd, 1, ";*/ ", 4); + InsertText(LocStart, "#if 0\n", 6); + ReplaceText(LocEnd, 1, ";\n#endif\n", 9); } else { InsertText(LocStart, "// ", 3); }