forked from OSchip/llvm-project
Remove references to the ast_type_traits namespace
Follow up to https://reviews.llvm.org/D92994
This commit is contained in:
parent
c28b18af19
commit
4c5e0c7fd8
|
@ -21,7 +21,7 @@ void DurationDivisionCheck::registerMatchers(MatchFinder *finder) {
|
|||
const auto DurationExpr =
|
||||
expr(hasType(cxxRecordDecl(hasName("::absl::Duration"))));
|
||||
finder->addMatcher(
|
||||
traverse(ast_type_traits::TK_AsIs,
|
||||
traverse(TK_AsIs,
|
||||
implicitCastExpr(
|
||||
hasSourceExpression(ignoringParenCasts(
|
||||
cxxOperatorCallExpr(hasOverloadedOperatorName("/"),
|
||||
|
|
|
@ -19,7 +19,6 @@
|
|||
#include <algorithm>
|
||||
|
||||
using namespace clang::ast_matchers;
|
||||
using namespace clang::ast_type_traits;
|
||||
|
||||
namespace clang {
|
||||
|
||||
|
|
|
@ -49,13 +49,13 @@ public:
|
|||
bool hidden() const override { return true; }
|
||||
|
||||
private:
|
||||
static bool dumpable(const ast_type_traits::DynTypedNode &N) {
|
||||
static bool dumpable(const DynTypedNode &N) {
|
||||
// Sadly not all node types can be dumped, and there's no API to check.
|
||||
// See DynTypedNode::dump().
|
||||
return N.get<Decl>() || N.get<Stmt>() || N.get<Type>();
|
||||
}
|
||||
|
||||
llvm::Optional<ast_type_traits::DynTypedNode> Node;
|
||||
llvm::Optional<DynTypedNode> Node;
|
||||
};
|
||||
REGISTER_TWEAK(DumpAST)
|
||||
|
||||
|
|
Loading…
Reference in New Issue