Lines Matching defs:TokenText

235     if (Tokens.back()->TokenText.size() == 1 &&
305 if (Tokens.back()->TokenText == "!cond")
339 At->TokenText = StringRef(At->TokenText.begin(),
340 String->TokenText.end() - At->TokenText.begin());
357 Hash->TokenText =
358 StringRef(Hash->TokenText.begin(),
359 Identifier->TokenText.end() - Hash->TokenText.begin());
381 if (Prefix->isNot(tok::at) && Prefix->TokenText != "$")
386 if ((Tok->TokenText == "$" && Prefix->is(tok::at)) ||
387 (Tok->is(tok::at) && Prefix->TokenText == "$")) {
397 Prefix->TokenText =
398 StringRef(Prefix->TokenText.begin(),
399 String->TokenText.end() - Prefix->TokenText.begin());
423 NullishCoalescing->TokenText =
424 StringRef(NullishCoalescing->TokenText.begin(),
425 Equal->TokenText.end() - NullishCoalescing->TokenText.begin());
439 if (Keyword->TokenText == "$")
445 At->TokenText = StringRef(At->TokenText.begin(),
446 Keyword->TokenText.end() - At->TokenText.begin());
460 if (Identifier->TokenText != "foreach")
477 if (Each->TokenText != "each")
483 For->TokenText = StringRef(For->TokenText.begin(),
484 Each->TokenText.end() - For->TokenText.begin());
532 First[0]->TokenText = "<<";
556 First[0]->TokenText = ">>";
586 AddLength += First[i]->TokenText.size();
590 First[0]->TokenText = StringRef(First[0]->TokenText.data(),
591 First[0]->TokenText.size() + AddLength);
663 const char *RegexBegin = Offset - RegexToken->TokenText.size();
692 RegexToken->TokenText = StringRef(RegexBegin, Offset - RegexBegin);
693 RegexToken->ColumnWidth = RegexToken->TokenText.size();
763 auto &TokenText = CSharpStringLiteral->TokenText;
767 if (TokenText.starts_with(R"($@")") || TokenText.starts_with(R"(@$")")) {
770 } else if (TokenText.starts_with(R"(@")")) {
772 } else if (TokenText.starts_with(R"($")")) {
780 const char *StrBegin = Lex->getBufferLocation() - TokenText.size();
796 TokenText = LiteralText;
830 MultiLineString->TokenText = Text;
856 StringRef Text = Tok->TokenText;
903 BacktickToken->TokenText == "`") {
911 const char *TmplBegin = Offset - BacktickToken->TokenText.size(); // at "`"
932 BacktickToken->TokenText = LiteralText;
960 Lex->getBufferLocation() - HashToken->TokenText.size(); // at "#"
968 HashToken->TokenText = Lex->getBuffer().substr(From, Len);
990 if (Macro->TokenText != "_T")
993 const char *Start = Macro->TokenText.data();
994 const char *End = Last->TokenText.data() + Last->TokenText.size();
995 String->TokenText = StringRef(Start, End - Start);
1001 String->TokenText, String->OriginalColumn, Style.TabWidth, Encoding);
1077 StringRef TokenText = FormatTok->TokenText;
1086 FormatTok->TokenText = TokenText;
1100 assert(NewLen <= FormatTok->TokenText.size());
1102 Lex->getBufferLocation() - FormatTok->TokenText.size() + NewLen)));
1103 FormatTok->TokenText = FormatTok->TokenText.substr(0, NewLen);
1105 FormatTok->TokenText, FormatTok->OriginalColumn, Style.TabWidth,
1164 auto LeadingWhitespace = countLeadingWhitespace(FormatTok->TokenText);
1167 if (LeadingWhitespace < FormatTok->TokenText.size())
1169 StringRef Text = FormatTok->TokenText;
1243 FormatTok->is(tok::comment) && FormatTok->TokenText.starts_with("//")) {
1244 size_t BackslashPos = FormatTok->TokenText.find('\\');
1246 if (BackslashPos + 1 < FormatTok->TokenText.size() &&
1247 FormatTok->TokenText[BackslashPos + 1] == '\n') {
1251 BackslashPos = FormatTok->TokenText.find('\\', BackslashPos + 1);
1265 auto Quote = FormatTok->TokenText.find('\'');
1271 if (FormatTok->TokenText == "`") {
1274 } else if (FormatTok->TokenText == "``") {
1279 NumberBase.match(FormatTok->TokenText, &Matches)) {
1298 StringRef UntrimmedText = FormatTok->TokenText;
1299 FormatTok->TokenText = FormatTok->TokenText.rtrim(" \t\v\f");
1300 TrailingWhitespace = UntrimmedText.size() - FormatTok->TokenText.size();
1302 IdentifierInfo &Info = IdentTable.get(FormatTok->TokenText);
1321 FormatTok->TokenText = FormatTok->TokenText.substr(0, 1);
1326 FormatTok->TokenText = FormatTok->TokenText.substr(0, 1);
1340 StringRef Text = FormatTok->TokenText;
1457 Tok.TokenText = StringRef(SourceMgr.getCharacterData(Tok.Tok.getLocation()),
1462 if (Tok.TokenText.starts_with("\"")) {
1465 } else if (Style.isJavaScript() && Tok.TokenText == "''") {
1473 if (Tok.is(tok::comment) && isClangFormatOn(Tok.TokenText))
1478 if (Tok.is(tok::comment) && isClangFormatOff(Tok.TokenText))