| /netbsd-src/external/apache2/llvm/dist/clang/lib/Format/ |
| H A D | FormatTokenLexer.cpp | 191 At->TokenText = StringRef(At->TokenText.begin(), in tryMergeNSStringLiteral() 192 String->TokenText.end() - At->TokenText.begin()); in tryMergeNSStringLiteral() 209 Hash->TokenText = in tryMergeJSPrivateIdentifier() 210 StringRef(Hash->TokenText.begin(), in tryMergeJSPrivateIdentifier() 211 Identifier->TokenText.end() - Hash->TokenText.begin()); in tryMergeJSPrivateIdentifier() 238 (CSharpInterpolatedString->TokenText.startswith(R"($")") || in tryMergeCSharpStringLiteral() 242 auto TokenTextSize = CSharpInterpolatedString->TokenText.size(); in tryMergeCSharpStringLiteral() 244 char C = CSharpInterpolatedString->TokenText[Index]; in tryMergeCSharpStringLiteral() 248 CSharpInterpolatedString->TokenText[Index + 1] == '{') { in tryMergeCSharpStringLiteral() 256 CSharpInterpolatedString->TokenText[Index + 1] == '}') { in tryMergeCSharpStringLiteral() [all …]
|
| H A D | BreakableToken.cpp | 222 StringRef Content = Token.TokenText.substr(2).ltrim(); in switchesFormatting() 274 assert(Tok.TokenText.startswith(Prefix) && Tok.TokenText.endswith(Postfix)); in BreakableStringLiteral() 275 Line = Tok.TokenText.substr( in BreakableStringLiteral() 276 Prefix.size(), Tok.TokenText.size() - Prefix.size() - Postfix.size()); in BreakableStringLiteral() 325 Text.data() - tokenAt(LineIndex).TokenText.data() + Split.first; in compressWhitespace() 376 StringRef TokenText(Tok.TokenText); in BreakableBlockComment() local 377 assert(TokenText.startswith("/*") && TokenText.endswith("*/")); in BreakableBlockComment() 378 TokenText.substr(2, TokenText.size() - 4) in BreakableBlockComment() 620 Text.data() - tokenAt(LineIndex).TokenText.data() + Split.first; in insertBreak() 666 tokenAt(LineIndex).TokenText.data(); in reflow() [all …]
|
| H A D | MacroExpander.cpp | 61 Def.Name = Current->TokenText; in parse() 80 Def.ArgMap[Def.Params.back()->TokenText] = Def.Params.size() - 1; in parseParams() 160 assert(defined(ID->TokenText)); in expand() 162 const Definition &Def = Definitions.find(ID->TokenText)->second; in expand() 178 if (!Tok->is(tok::identifier) || ExpandedArgs.contains(Tok->TokenText)) in expand() 180 ExpandedArgs.insert(Tok->TokenText); in expand() 181 auto I = Def.ArgMap.find(Tok->TokenText); in expand()
|
| H A D | NamespaceEndCommentsFixer.cpp | 39 name += Tok->TokenText; in computeName() 55 name += Tok->TokenText; in computeName() 69 text += NamespaceTok->TokenText; in computeEndCommentText() 104 NamespaceMacroCommentPattern.match(Comment->TokenText, &Groups)) { in validEndComment() 107 if (NamespaceTokenText != NamespaceTok->TokenText) in validEndComment() 110 !NamespaceCommentPattern.match(Comment->TokenText, &Groups)) { in validEndComment() 135 if (!CommentPattern.match(Comment->Next->TokenText, &Groups)) { in validEndComment() 193 return NamespaceTok ? NamespaceTok->TokenText : StringRef(); in getNamespaceTokenText() 248 NamespaceTokenText = NamespaceTok->TokenText; in analyze()
|
| H A D | SortJavaScriptImports.cpp | 191 FirstNonImportLine->First->TokenText.trim() == "// clang-format on")) in analyze() 362 StringRef CommentText = Current->TokenText.trim(); in parseModuleReferences() 437 Current->TokenText.substr(1, Current->TokenText.size() - 2); in parseModuleReference() 451 Current->TokenText.substr(1, Current->TokenText.size() - 2); in parseModuleReference() 484 Reference.Prefix = Current->TokenText; in parseStarBinding() 493 Reference.DefaultImport = Current->TokenText; in parseNamedBindings() 514 Symbol.Symbol = Current->TokenText; in parseNamedBindings() 524 Symbol.Alias = Current->TokenText; in parseNamedBindings()
|
| H A D | ContinuationIndenter.cpp | 149 static llvm::Optional<StringRef> getRawStringDelimiter(StringRef TokenText) { in getRawStringDelimiter() argument 150 if (TokenText.size() < 5 // The smallest raw string possible is 'R"()"'. in getRawStringDelimiter() 151 || !TokenText.startswith("R\"") || !TokenText.endswith("\"")) in getRawStringDelimiter() 157 size_t LParenPos = TokenText.substr(0, 19).find_first_of('('); in getRawStringDelimiter() 160 StringRef Delimiter = TokenText.substr(2, LParenPos - 2); in getRawStringDelimiter() 163 size_t RParenPos = TokenText.size() - Delimiter.size() - 2; in getRawStringDelimiter() 164 if (TokenText[RParenPos] != ')') in getRawStringDelimiter() 166 if (!TokenText.substr(RParenPos + 1).startswith(Delimiter)) in getRawStringDelimiter() 511 ((Previous.is(tok::identifier) && Previous.TokenText == "endl") || in mustBreak() 512 (Previous.Tok.isLiteral() && (Previous.TokenText.endswith("\\n\"") || in mustBreak() [all …]
|
| H A D | UnwrappedLineParser.cpp | 61 return FormatTok.is(tok::comment) && !FormatTok.TokenText.startswith("/*"); in isLineComment() 669 if (I->Tok->TokenText != "goog") in isGoogScope() 675 if (I->Tok->TokenText != "scope") in isGoogScope() 821 if (!IfDef && (FormatTok->is(tok::kw_false) || FormatTok->TokenText == "0")) in parsePPIf() 823 if (IfDef && !IfNDef && FormatTok->TokenText == "SWIG") in parsePPIf() 884 IncludeGuardToken->TokenText == FormatTok->TokenText) { in parsePPDefine() 1016 Previous->is(TT_TemplateString) && Previous->TokenText.endswith("${"); in readTokenWithJavaScriptASI() 1031 Next->is(TT_TemplateString) && Next->TokenText.startswith("}"); in readTokenWithJavaScriptASI() 1446 StringRef Text = FormatTok->TokenText; in parseStructuralElement() 2676 FormatTok->TokenText != FormatTok->TokenText.upper(); in parseRecord() [all …]
|
| H A D | TokenAnnotator.cpp | 1156 !CurrentToken->TokenText.startswith("//")) in parseIncludeDirective() 1349 return Tok.TokenText == "goog" && Tok.Next && Tok.Next->is(tok::period) && in isClosureImportStatement() 1351 (Tok.Next->Next->TokenText == "module" || in isClosureImportStatement() 1352 Tok.Next->Next->TokenText == "provide" || in isClosureImportStatement() 1353 Tok.Next->Next->TokenText == "require" || in isClosureImportStatement() 1354 Tok.Next->Next->TokenText == "requireType" || in isClosureImportStatement() 1355 Tok.Next->Next->TokenText == "forwardDeclare") && in isClosureImportStatement() 1555 LeadingIdentifier->TokenText == Current.Next->TokenText); in isDeductionGuide() 1652 if (Current.TokenText.startswith("/*")) { in determineTokenType() 1653 if (Current.TokenText.endswith("*/")) in determineTokenType() [all …]
|
| H A D | UnwrappedLineFormatter.cpp | 158 return NamespaceToken ? NamespaceToken->TokenText : StringRef(); in getNamespaceTokenText() 166 return NamespaceToken ? NamespaceToken->TokenText : StringRef(); in getMatchingNamespaceTokenText() 277 nsToken->TokenText == getNamespaceTokenText(I[i + 1]) && in tryFitMultipleLinesInOne() 293 nsToken->TokenText == in tryFitMultipleLinesInOne() 769 llvm::dbgs() << (P.Tok ? P.Tok->TokenText : "F") << "|" << P.Indent << "|" in printLineState() 772 llvm::dbgs() << State.NextToken->TokenText << "\n"; in printLineState()
|
| H A D | FormatToken.h | 226 StringRef TokenText; member 526 if (is(TT_TemplateString) && TokenText.endswith("${")) in opensScope() 536 if (is(TT_TemplateString) && TokenText.startswith("}")) in closesScope() 605 StringRef Content = TokenText; in isLabelString()
|
| H A D | AffectedRangeManager.cpp | 79 End = End.getLocWithOffset(Last.TokenText.size()); in affectsTokenRange()
|
| H A D | UsingDeclarationsSorter.cpp | 102 Label.append(Tok->TokenText.str()); in computeUsingDeclarationLabel()
|
| H A D | Format.cpp | 1560 StringRef Input = FormatTok->TokenText; in requoteJSStringLiteral() 1795 Prev->Tok.getLocation().getLocWithOffset(Prev->TokenText.size()); in insertTrailingCommas() 2137 if (Line->First && (Line->First->TokenText.startswith("#") || in guessIsObjC() 2138 Line->First->TokenText == "__pragma" || in guessIsObjC() 2139 Line->First->TokenText == "_Pragma")) in guessIsObjC() 2150 FormatTok->TokenText)) || in guessIsObjC() 2161 << " token: " << FormatTok->TokenText << " token type: " in guessIsObjC()
|
| /netbsd-src/external/apache2/llvm/dist/clang/lib/Frontend/ |
| H A D | PrintPreprocessedOutput.cpp | 341 const std::string TokenText = PP.getSpelling(IncludeTok); in InclusionDirective() local 342 assert(!TokenText.empty()); in InclusionDirective() 343 OS << "#" << TokenText << " " in InclusionDirective()
|
| /netbsd-src/external/apache2/llvm/dist/clang/lib/ASTMatchers/ |
| H A D | ASTMatchersInternal.cpp | 683 StringRef TokenText = Lexer::getSpelling(SM.getSpellingLoc(Loc), Buffer, SM, in isTokenAtLoc() local 685 return !Invalid && Text == TokenText; in isTokenAtLoc()
|