[cfe-commits] r49404 - /cfe/trunk/lib/Rewrite/HTMLRewrite.cpp
Ted Kremenek
kremenek at apple.com
Tue Apr 8 15:28:18 PDT 2008
Author: kremenek
Date: Tue Apr 8 17:28:15 2008
New Revision: 49404
URL: http://llvm.org/viewvc/llvm-project?rev=49404&view=rev
Log:
When substituting tabs during HTMLification, only add " " when we are
"escaping" spaces.
Modified:
cfe/trunk/lib/Rewrite/HTMLRewrite.cpp
Modified: cfe/trunk/lib/Rewrite/HTMLRewrite.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Rewrite/HTMLRewrite.cpp?rev=49404&r1=49403&r2=49404&view=diff
==============================================================================
--- cfe/trunk/lib/Rewrite/HTMLRewrite.cpp (original)
+++ cfe/trunk/lib/Rewrite/HTMLRewrite.cpp Tue Apr 8 17:28:15 2008
@@ -42,7 +42,12 @@
case '\t': {
SourceLocation Loc = SourceLocation::getFileLoc(FileID, FilePos);
- R.ReplaceText(Loc, 1, " ", 6*4);
+
+ if (EscapeSpaces)
+ R.ReplaceText(Loc, 1, " ", 6*4);
+ else
+ R.ReplaceText(Loc, 1, " ", 4);
+
break;
}
More information about the cfe-commits
mailing list