macro expansions.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49877
91177308-0d34-0410-b5e6-
96231b3b80d8
}
LineLen -= Expansion.size();
- Expansion += ' ' + PP->getSpelling(Tok);
+ // Escape any special characters in the token text.
+ Expansion += ' ' + EscapeText(PP->getSpelling(Tok));
LineLen += Expansion.size();
PP->Lex(Tok);
}
-
+
// Insert the information about the expansion inside the macro span.
Expansion = "<span class='expansion'>" + Expansion + "</span>";
RB.InsertTextBefore(TokOffs+TokLen, Expansion.c_str(), Expansion.size());