summaryrefslogtreecommitdiff
path: root/clang-tools-extra/clang-move
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2018-08-31 03:51:33 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2018-08-31 03:51:33 +0000
commit2b6ec65696922432c60da5411c8b2ecd3264864b (patch)
treef38a433eaaa90aa0c0dd4dc0ee7050b41cdf6d52 /clang-tools-extra/clang-move
parent53cb061b328b497036630ce19521a5870c30a941 (diff)
downloadllvm-2b6ec65696922432c60da5411c8b2ecd3264864b.tar.gz
[clang-move] Explicitly ignore implicit UsingDirectiveDecls instead of depending on them missing source locations
This is adjustment to allow the logic to work even if implicit UsingDirectiveDecls get actual source locations. There should be no functionality change. llvm-svn: 341161
Diffstat (limited to 'clang-tools-extra/clang-move')
-rw-r--r--clang-tools-extra/clang-move/ClangMove.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang-tools-extra/clang-move/ClangMove.cpp b/clang-tools-extra/clang-move/ClangMove.cpp
index eac6fcd0ec73..f20cf1ec4ca2 100644
--- a/clang-tools-extra/clang-move/ClangMove.cpp
+++ b/clang-tools-extra/clang-move/ClangMove.cpp
@@ -558,7 +558,8 @@ void ClangMoveTool::registerMatchers(ast_matchers::MatchFinder *Finder) {
// namespace, these decls are always copied to new.h/cc. Those in classes,
// functions are covered in other matchers.
Finder->addMatcher(namedDecl(anyOf(usingDecl(IsOldCCTopLevelDecl),
- usingDirectiveDecl(IsOldCCTopLevelDecl),
+ usingDirectiveDecl(unless(isImplicit()),
+ IsOldCCTopLevelDecl),
typeAliasDecl(IsOldCCTopLevelDecl)),
notInMacro())
.bind("using_decl"),