clang-tools 6.0.0

LexerUtils.h
Go to the documentation of this file.
1 //===--- LexerUtils.h - clang-tidy-------------------------------*- C++ -*-===//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9
10 #ifndef LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_UTILS_LEXER_UTILS_H
11 #define LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_UTILS_LEXER_UTILS_H
12
13 #include "clang/AST/ASTContext.h"
14 #include "clang/Lex/Lexer.h"
15
16 namespace clang {
17 namespace tidy {
18 namespace utils {
19 namespace lexer {
20
21 /// Returns previous token or ``tok::unknown`` if not found.
22 Token getPreviousToken(const ASTContext &Context, SourceLocation Location,
23 bool SkipComments = true);
24
25 } // namespace lexer
26 } // namespace utils
27 } // namespace tidy
28 } // namespace clang
29
30 #endif // LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_UTILS_LEXER_UTILS_H
clang::tidy::utils::lexer::getPreviousToken
Token getPreviousToken(const ASTContext &Context, SourceLocation Location, bool SkipComments)
Returns previous token or tok::unknown if not found.
Definition: LexerUtils.cpp:17
clang
Definition: AndroidTidyModule.cpp:28
Location
Definition: Modularize.cpp:384