Searched refs:Tokens (Results 1 - 25 of 42) sorted by relevance

12

/freebsd-11-stable/contrib/llvm-project/clang/lib/Format/
H A DFormatTokenLexer.cpp49 assert(Tokens.empty());
52 Tokens.push_back(getNextToken());
60 if (Tokens.back()->NewlinesBefore > 0 || Tokens.back()->IsMultiline)
61 FirstInLineIndex = Tokens.size() - 1;
62 } while (Tokens.back()->Tok.isNot(tok::eof));
63 return Tokens;
120 Tokens.back()->Tok.setKind(tok::starequal);
128 Tokens.back()->Tok.setKind(tok::period);
144 if (Tokens
[all...]
H A DUsingDeclarationsSorter.h30 FormatTokenLexer &Tokens) override;
H A DTokenAnnotator.h40 : First(Line.Tokens.front().Tok), Level(Line.Level),
48 assert(!Line.Tokens.empty());
55 for (std::list<UnwrappedLineNode>::const_iterator I = ++Line.Tokens.begin(),
56 E = Line.Tokens.end();
86 template <typename... Ts> bool startsWith(Ts... Tokens) const {
87 return First && First->startsSequence(Tokens...);
94 template <typename... Ts> bool endsWith(Ts... Tokens) const {
95 return Last && Last->endsSequence(Tokens...);
H A DNamespaceEndCommentsFixer.h40 FormatTokenLexer &Tokens) override;
H A DTokenAnalyzer.cpp67 FormatTokenLexer Tokens(Env.getSourceManager(), Env.getFileID(),
70 UnwrappedLineParser Parser(Style, Tokens.getKeywords(),
71 Env.getFirstStartColumn(), Tokens.lex(), *this);
79 TokenAnnotator Annotator(Style, Tokens.getKeywords());
86 analyze(Annotator, AnnotatedLines, Tokens);
H A DUnwrappedLineParser.cpp145 else if (!Parser.Line->Tokens.empty())
146 Parser.CurrentLines = &Parser.Line->Tokens.back().Children;
154 if (!Parser.Line->Tokens.empty()) {
157 assert(Parser.Line->Tokens.empty());
197 IndexedTokenSource(ArrayRef<FormatToken *> Tokens) argument
198 : Tokens(Tokens), Position(-1) {}
202 return Tokens[Position];
212 return Tokens[Position];
218 ArrayRef<FormatToken *> Tokens; member in class:clang::format::__anon493::IndexedTokenSource
224 UnwrappedLineParser(const FormatStyle &Style, const AdditionalKeywords &Keywords, unsigned FirstStartColumn, ArrayRef<FormatToken *> Tokens, UnwrappedLineConsumer &Callback) argument
[all...]
H A DUnwrappedLineParser.h40 /// The \c Tokens comprising this \c UnwrappedLine.
41 std::list<UnwrappedLineNode> Tokens; member in struct:clang::format::UnwrappedLine
79 unsigned FirstStartColumn, ArrayRef<FormatToken *> Tokens,
210 FormatTokenSource *Tokens; member in class:clang::format::UnwrappedLineParser
H A DTokenAnalyzer.h90 FormatTokenLexer &Tokens) = 0;
H A DFormatTokenLexer.h105 // Index (in 'Tokens') of the last token that starts a new line.
107 SmallVector<FormatToken *, 16> Tokens; member in class:clang::format::FormatTokenLexer
H A DBreakableToken.cpp300 return Tokens[LineIndex] ? *Tokens[LineIndex] : Tok;
354 Tokens.resize(Lines.size());
628 assert(Tokens[LineIndex - 1] == Tokens[LineIndex] &&
741 Tokens.resize(Lines.size());
770 Tokens[i] = LineTok;
862 if (LineIndex > 0 && Tokens[LineIndex] != Tokens[LineIndex - 1]) {
866 *Tokens[LineInde
[all...]
H A DFormatToken.h348 bool startsSequence(A K1, Ts... Tokens) const {
349 return startsSequenceInternal(K1, Tokens...);
359 bool endsSequence(A K1, Ts... Tokens) const {
360 return endsSequenceInternal(K1, Tokens...);
558 bool startsSequenceInternal(A K1, Ts... Tokens) const {
560 return Next->startsSequenceInternal(K1, Tokens...);
561 return is(K1) && Next && Next->startsSequenceInternal(Tokens...);
577 bool endsSequenceInternal(A K1, Ts... Tokens) const {
579 return Previous->endsSequenceInternal(K1, Tokens...);
580 return is(K1) && Previous && Previous->endsSequenceInternal(Tokens
[all...]
/freebsd-11-stable/contrib/llvm-project/clang/lib/Tooling/Syntax/
H A DSynthesis.cpp26 auto Tokens = A.lexBuffer(llvm::MemoryBuffer::getMemBuffer( local
29 assert(Tokens.size() == 1);
30 assert(Tokens.front().kind() == K);
31 auto *L = new (A.allocator()) clang::syntax::Leaf(Tokens.begin());
H A DComputeReplacements.cpp10 #include "clang/Tooling/Syntax/Tokens.h"
103 &TU, [&](llvm::ArrayRef<syntax::Token> Tokens, bool IsOriginal) {
106 syntax::Token::range(SM, Tokens.front(), Tokens.back()).text(SM);
109 assert(NextOriginal <= Tokens.begin());
111 if (NextOriginal != Tokens.begin()) {
113 emitReplacement(llvm::makeArrayRef(NextOriginal, Tokens.begin()));
118 NextOriginal = Tokens.end();
H A DBuildTree.cpp19 #include "clang/Tooling/Syntax/Tokens.h"
87 auto Tokens = Arena.tokenBuffer().expandedTokens(); local
88 assert(!Tokens.empty());
89 assert(Tokens.back().kind() == tok::eof);
92 Pending.foldChildren(Arena, Tokens.drop_back(),
113 auto Tokens = getRange(D->getBeginLoc(), D->getEndLoc()); local
115 return Tokens;
117 return Tokens;
120 return withTrailingSemicolon(Tokens);
128 auto Tokens local
188 foldChildren(const syntax::Arena &A, llvm::ArrayRef<syntax::Token> Tokens, syntax::Tree *Node) argument
207 foldChildrenDelayed(llvm::ArrayRef<syntax::Token> Tokens, syntax::Tree *Node) argument
257 foldChildrenEager(const syntax::Arena &A, llvm::ArrayRef<syntax::Token> Tokens, syntax::Tree *Node) argument
423 auto Tokens = Builder.getRange(S); local
[all...]
H A DTree.cpp36 TokenBuffer Tokens)
37 : SourceMgr(SourceMgr), LangOpts(LangOpts), Tokens(std::move(Tokens)) {}
40 return Tokens;
127 static void dumpTokens(llvm::raw_ostream &OS, ArrayRef<syntax::Token> Tokens, argument
129 assert(!Tokens.empty());
131 for (const auto &T : Tokens) {
35 Arena(SourceManager &SourceMgr, const LangOptions &LangOpts, TokenBuffer Tokens) argument
H A DTokens.cpp1 //===- Tokens.cpp - collect tokens from preprocessing ---------------------===//
8 #include "clang/Tooling/Syntax/Tokens.h"
259 const syntax::TokenBuffer &Tokens) {
262 Tokens.spelledTokens(Tokens.sourceManager().getFileID(Loc));
273 const syntax::TokenBuffer &Tokens) {
274 for (const syntax::Token &Tok : spelledTokensTouching(Loc, Tokens)) {
298 std::vector<syntax::Token> Tokens; local
308 Tokens.push_back(syntax::Token(T));
320 return Tokens;
258 spelledTokensTouching(SourceLocation Loc, const syntax::TokenBuffer &Tokens) argument
272 spelledIdentifierTouching(SourceLocation Loc, const syntax::TokenBuffer &Tokens) argument
[all...]
/freebsd-11-stable/contrib/llvm-project/llvm/include/llvm/Support/
H A DGlobPattern.h38 std::vector<BitVector> Tokens; member in class:llvm::GlobPattern
/freebsd-11-stable/contrib/llvm-project/clang/lib/Lex/
H A DTokenLexer.cpp53 Tokens = &*Macro->tokens_begin();
64 assert(Tokens[0].getLocation().isValid());
65 assert((Tokens[0].getLocation().isFileID() || Tokens[0].is(tok::comment)) &&
70 // definition. Tokens that get lexed directly from the definition will
73 MacroDefStart = SM.getExpansionLoc(Tokens[0].getLocation());
82 // Tokens to point to the expanded tokens.
104 Tokens = TokArray;
128 delete [] Tokens;
129 Tokens
[all...]
H A DDependencyDirectivesSourceMinimizer.cpp34 SmallVectorImpl<Token> &Tokens; member in struct:__anon544::Minimizer
36 Minimizer(SmallVectorImpl<char> &Out, SmallVectorImpl<Token> &Tokens, argument
39 : Out(Out), Tokens(Tokens), Input(Input), Diags(Diags),
69 Tokens.emplace_back(K, Out.size());
70 return Tokens.back();
73 Out.resize(Tokens.back().Offset);
74 Tokens.pop_back();
76 TokenKind top() const { return Tokens.empty() ? pp_none : Tokens
949 minimizeSourceToDependencyDirectives( StringRef Input, SmallVectorImpl<char> &Output, SmallVectorImpl<Token> &Tokens, DiagnosticsEngine *Diags, SourceLocation InputSourceLoc) argument
[all...]
/freebsd-11-stable/contrib/llvm-project/clang/include/clang/Lex/
H A DDependencyDirectivesSourceMinimizer.h104 &Tokens,
H A DTokenLexer.h51 const Token *Tokens; member in class:clang::TokenLexer
53 /// This is the length of the Tokens array.
89 /// This is true if this TokenLexer allocated the Tokens
163 /// Concatenates the next (sub-)sequence of \p Tokens separated by '##'
172 /// Tokens upon entry and will contain the resulting concatenated Token upon
175 /// \param[in] TokenStream - The stream of Tokens we are lexing from.
187 /// Calls pasteTokens above, passing in the '*this' object's Tokens and
197 /// \param[in,out] ResultToks - Contains the current Replacement Tokens
210 /// return preexpanded tokens from Tokens.
/freebsd-11-stable/contrib/llvm-project/clang/include/clang/Tooling/Syntax/
H A DTree.h28 #include "clang/Tooling/Syntax/Tokens.h"
42 TokenBuffer Tokens);
59 TokenBuffer Tokens; member in class:clang::syntax::Arena
H A DTokens.h1 //===- Tokens.h - collect tokens from preprocessing --------------*- C++-*-===//
182 /// Tokens are in TU order (per SourceManager::isBeforeInTranslationUnit()).
319 spelledTokensTouching(SourceLocation Loc, const syntax::TokenBuffer &Tokens);
325 const syntax::TokenBuffer &Tokens);
/freebsd-11-stable/contrib/llvm-project/llvm/lib/Support/
H A DGlobPattern.cpp138 Pat.Tokens.push_back(*BV);
150 return matchOne(Tokens, S);
/freebsd-11-stable/contrib/llvm-project/clang/lib/Tooling/DependencyScanning/
H A DDependencyScanningFilesystem.cpp38 SmallVector<minimize_source_to_dependency_directives::Token, 64> Tokens; local
40 Buffer->getBuffer(), MinimizedFileContents, Tokens)) {
77 minimize_source_to_dependency_directives::computeSkippedRanges(Tokens,

Completed in 245 milliseconds

12