aboutsummaryrefslogtreecommitdiff
path: root/lib/Lex
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Lex')
-rw-r--r--lib/Lex/LiteralSupport.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Lex/LiteralSupport.cpp b/lib/Lex/LiteralSupport.cpp
index e3ff77f4f0..e0bdc5f858 100644
--- a/lib/Lex/LiteralSupport.cpp
+++ b/lib/Lex/LiteralSupport.cpp
@@ -791,6 +791,7 @@ CharLiteralParser::CharLiteralParser(const char *begin, const char *end,
--end;
} while (end[-1] != '\'');
UDSuffixBuf.assign(end, UDSuffixEnd);
+ UDSuffixOffset = end - begin + 1;
}
// Trim the ending quote.
@@ -1113,6 +1114,8 @@ void StringLiteralParser::init(const Token *StringToks, unsigned NumStringToks){
if (UDSuffixBuf.empty()) {
UDSuffixBuf.assign(UDSuffix);
+ UDSuffixToken = i;
+ UDSuffixOffset = ThisTokEnd - ThisTokBuf;
UDSuffixTokLoc = StringToks[i].getLocation();
} else if (!UDSuffixBuf.equals(UDSuffix)) {
// C++11 [lex.ext]p8: At the end of phase 6, if a string literal is the