[PATCH] D97513: [CMake] Add ConfigVersion.cmake files

2021-03-27 Thread Stephen Kelly via Phabricator via cfe-commits
steveire accepted this revision. steveire added a comment. This revision is now accepted and ready to land. LGTM, thanks! I'll commit this on Wednesday if none of the other reviewers object by then. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97513/new/ https://reviews.llvm.org/D9751

[PATCH] D98296: [clang-tidy] Simplify readability checks to not need ignoring* matchers

2021-03-27 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 333696. steveire added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D98296/new/ https://reviews.llvm.org/D98296 Files: clang-tools-extra/clang-tidy/readability/BracesAroundStatementsCheck.

[PATCH] D98296: [clang-tidy] Simplify readability checks to not need ignoring* matchers

2021-03-28 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGea2225a10be9: [clang-tidy] Simplify readability checks to not need ignoring* matchers (authored by stephenkelly). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.or

[PATCH] D69218: [ASTMatchers] Add `cxxBaseSpecifier` matcher (non-top-level)

2021-03-28 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. @nick Sorry that getting these changes merged takes so long. @njames93 If you have an alternative way forward, please let us know what it is. Otherwise, this LGTM too and we should merge it soon unless there are objections which haven't been addressed. =

[PATCH] D69218: [ASTMatchers] Add `cxxBaseSpecifier` matcher (non-top-level)

2021-03-28 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. @nick I think this also might need to be rebased again, sorry. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69218/new/ https://reviews.llvm.org/D69218 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://

[PATCH] D99715: [CMake] Respect LLVM_MINIMUM_PYTHON_VERSION in Tooling/CMakeLists.txt

2021-04-03 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a reviewer: steveire. steveire added a comment. Yes, please remove the line instead. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99715/new/ https://reviews.llvm.org/D99715 ___ cfe-commit

[PATCH] D69218: [ASTMatchers] Add `cxxBaseSpecifier` matcher (non-top-level)

2021-04-03 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. In D69218#2654638 , @nick wrote: > In D69218#2654614 , @steveire wrote: > >> @nick Sorry that getting these changes merged takes so long. >> >> @njames93 If you have an alternative way forw

[PATCH] D99231: [AST] Add introspection support for more base nodes

2021-04-07 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. @njames93 ping? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99231/new/ https://reviews.llvm.org/D99231 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.ll

[PATCH] D69218: [ASTMatchers] Add `cxxBaseSpecifier` matcher (non-top-level)

2021-04-08 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG2f181086b5cb: [ASTMatchers] Add `cxxBaseSpecifier` matcher (non-to

[PATCH] D99231: [AST] Add introspection support for more base nodes

2021-04-11 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 336651. steveire added a comment. Add locations for CXXBaseSpecifier Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99231/new/ https://reviews.llvm.org/D99231 Files: clang/include/clang/AST/DeclCXX.h clang

[PATCH] D93325: Add srcloc output to clang-query

2021-04-11 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 336652. steveire added a comment. Herald added a subscriber: mgorny. Herald added a project: clang-tools-extra. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93325/new/ https://reviews.llvm.org/D93325

[PATCH] D93325: Add srcloc output to clang-query

2021-04-11 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 336690. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93325/new/ https://reviews.llvm.org/D93325 Files: clang-tools-extra/clang-query/CMakeLists.txt clang-tools-extra/clan

[PATCH] D99231: [AST] Add introspection support for more base nodes

2021-04-12 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 336804. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99231/new/ https://reviews.llvm.org/D99231 Files: clang/include/clang/AST/DeclCXX.h clang/include/clang/Tooling/NodeI

[PATCH] D99231: [AST] Add introspection support for more base nodes

2021-04-12 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/include/clang/AST/DeclCXX.h:2270 SourceLocation getEllipsisLoc() const { -assert(isPackExpansion() && "Initializer is not a pack expansion"); +if (!isPackExpansion()) + return {}; njames93 wrote: >

[PATCH] D99231: [AST] Add introspection support for more base nodes

2021-04-12 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 336813. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99231/new/ https://reviews.llvm.org/D99231 Files: clang/include/clang/AST/DeclCXX.h clang/include/clang/Tooling/NodeI

[PATCH] D99231: [AST] Add introspection support for more base nodes

2021-04-13 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/include/clang/AST/DeclCXX.h:2270 SourceLocation getEllipsisLoc() const { -assert(isPackExpansion() && "Initializer is not a pack expansion"); +if (!isPackExpansion()) + return {}; njames93 wrote: >

[PATCH] D99231: [AST] Add introspection support for more base nodes

2021-04-14 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGf347f0e0b869: [AST] Add introspection support for more base nodes (authored by stephenkelly). Changed prior to commit: https://reviews.llvm.org/D99231?vs=336813&id=337537#toc Repository: rG LLVM Gith

[PATCH] D100378: [AST] Use IntrusiveRefCntPtr for Introspection LocationCall.

2021-04-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. Indeed, I just this evening discovered the need for this to be stable across runs for testing. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100378/new/ https://reviews.llvm.org/D100378 __

[PATCH] D100423: [AST] Add a print method to Introspection LocationCall

2021-04-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire requested changes to this revision. steveire added inline comments. This revision now requires changes to proceed. Comment at: clang/lib/Tooling/NodeIntrospection.cpp:26 +if (On->returnsPointer()) + OS << "->"; +else The reason for the `Loca

[PATCH] D100516: [AST] Add TypeLoc support to node introspection

2021-04-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: njames93. Herald added subscribers: mgrang, mgorny. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Extend the matchers gathering API for types to record template parameter

[PATCH] D100548: [AST] Fix location call storage with common last-invocation

2021-04-15 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: njames93. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Also fix the formatter to use the front element of a chained call instead of the back element. Repository: rG

[PATCH] D100516: [AST] Add TypeLoc support to node introspection

2021-04-15 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 337720. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100516/new/ https://reviews.llvm.org/D100516 Files: clang/include/clang/Tooling/NodeIntrospection.h clang/lib/Tooling

[PATCH] D100423: [AST] Add a print method to Introspection LocationCall

2021-04-15 Thread Stephen Kelly via Phabricator via cfe-commits
steveire accepted this revision. steveire added a comment. This revision is now accepted and ready to land. Thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100423/new/ https://reviews.llvm.org/D100423

[PATCH] D100548: [AST] Fix location call storage with common last-invocation

2021-04-15 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG4f6d69846747: [AST] Fix location call storage with common last-invocation (authored by stephenkelly). Changed prior to commit: https://reviews.llvm.org/D100548?vs=337713&id=337917#toc Repository: rG

[PATCH] D100516: [AST] Add TypeLoc support to node introspection

2021-04-15 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 337923. steveire edited the summary of this revision. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100516/new/ https://reviews.llvm.org/D100516 Files: clang/include/clang/T

[PATCH] D100516: [AST] Add TypeLoc support to node introspection

2021-04-15 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/unittests/Introspection/IntrospectionTest.cpp:1294 + +#ifndef _WIN32 +TEST(Introspection, SourceLocations_TypeOfTypeLoc) { njames93 wrote: > Can you add a comment explaining the issues with this test on windows >

[PATCH] D100516: [AST] Add TypeLoc support to node introspection

2021-04-16 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 338030. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100516/new/ https://reviews.llvm.org/D100516 Files: clang/include/clang/Tooling/NodeIntrospection.h clang/lib/Tooling

[PATCH] D100516: [AST] Add TypeLoc support to node introspection

2021-04-16 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 338049. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100516/new/ https://reviews.llvm.org/D100516 Files: clang/include/clang/Tooling/NodeIntrospection.h clang/lib/Tooling

[PATCH] D100638: [AST][Introspection] Avoid creating temporary strings when comparing LocationCalls.

2021-04-16 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/lib/Tooling/NodeIntrospection.cpp:84 + + auto LI = Left.rbegin(), LE = Left.rend(), RI = Right.rbegin(); + for (; LI != LE; ++LI, ++RI) { Would it make sense to compare the sizes `(leftsize < rightsize) return t

[PATCH] D100638: [AST][Introspection] Avoid creating temporary strings when comparing LocationCalls.

2021-04-16 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/lib/Tooling/NodeIntrospection.cpp:84 + + auto LI = Left.rbegin(), LE = Left.rend(), RI = Right.rbegin(); + for (; LI != LE; ++LI, ++RI) { njames93 wrote: > steveire wrote: > > Would it make sense to compare the

[PATCH] D100688: [AST] Remove args from LocationCall

2021-04-16 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: njames93. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This class initially had args to be generic to future needs. In particular, I thought that source location introsp

[PATCH] D100688: [AST] Remove args from LocationCall

2021-04-17 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGebc6608fb790: [AST] Remove args from LocationCall (authored by stephenkelly). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100688/new/ https://reviews.llvm

[PATCH] D100516: [AST] Add TypeLoc support to node introspection

2021-04-17 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGdd68942f1d79: [AST] Add TypeLoc support to node introspection (authored by stephenkelly). Changed prior to commit: https://reviews.llvm.org/D100516?vs=338049&id=338342#toc Repository: rG LLVM Github

[PATCH] D100516: [AST] Add TypeLoc support to node introspection

2021-04-17 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/lib/Tooling/DumpTool/ASTSrcLocProcessor.cpp:172-176 + if (TypeLocBase && Node->getName() == "getLocalSourceRange") +continue; + if ((ASTClass->getName() == "PointerLikeTypeLoc" || + ASTClass->getName()

[PATCH] D100712: [AST] Add NestedNameSpecifierLoc accessors to node introspection

2021-04-17 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: njames93. Herald added subscribers: mgrang, mgorny. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Change the GetLocations API to take instances by const-ref. This class

[PATCH] D100720: [AST] Update introspection API to use const-ref for copyable types

2021-04-18 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: njames93. Herald added a subscriber: mgorny. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D100720 Files:

[PATCH] D100719: [Introspection] Dont emit json if unchanged.

2021-04-18 Thread Stephen Kelly via Phabricator via cfe-commits
steveire accepted this revision. steveire added a comment. This revision is now accepted and ready to land. Great, thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100719/new/ https://reviews.llvm.org/D100719 _

[PATCH] D100723: [AST] Fix comparison to of SourceRanges in container

2021-04-18 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: njames93. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D100723 Files: clang/lib/Tooling/NodeIntrospect

[PATCH] D100638: [AST][Introspection] Avoid creating temporary strings when comparing LocationCalls.

2021-04-18 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. Your implementation is getting very complicated and it requires many comments. Also, if we get to this point in the execution of `RangeLessThan::operator()`, you're creating and populating two vectors for every two elements contained. I know it's `llvm::SmallVector` an

[PATCH] D100723: [AST] Fix comparison to of SourceRanges in container

2021-04-18 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/lib/Tooling/NodeIntrospection.cpp:47 std::pair const &RHS) const { - if (!LHS.first.isValid() || !RHS.first.isValid()) -return false; njames93 wrote: > Maybe we should assert the ranges (or locations) ar

[PATCH] D100712: [AST] Add NestedNameSpecifierLoc accessors to node introspection

2021-04-18 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/lib/Tooling/DumpTool/generate_cxx_src_locs.py:57 InstanceDecoration = "*" -if CladeName == "TypeLoc": +if CladeName == "TypeLoc" or CladeName == "NestedNameSpecifierLoc": InstanceDecoration =

[PATCH] D100712: [AST] Add NestedNameSpecifierLoc accessors to node introspection

2021-04-18 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/unittests/Introspection/IntrospectionTest.cpp:280 STRING_LOCATION_STDPAIR(MethodDecl, getTypeSpecStartLoc()) })); // clang-format on njames93 wrote: > I'm not entirely sure on the case, but the windows bot

[PATCH] D100720: [AST] Update introspection API to use const-ref for copyable types

2021-04-19 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGabacaef18162: [AST] Update introspection API to use const-ref for copyable types (authored by stephenkelly). Changed prior to commit: https://reviews.llvm.org/D100720?vs=338366&id=338613#toc Repository

[PATCH] D100723: [AST] Fix comparison to of SourceRanges in container

2021-04-19 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG782c3e23ba09: [AST] Fix comparison to of SourceRanges in container (authored by stephenkelly). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100723/new/ htt

[PATCH] D100712: [AST] Add NestedNameSpecifierLoc accessors to node introspection

2021-04-19 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 338620. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100712/new/ https://reviews.llvm.org/D100712 Files: clang/lib/Tooling/DumpTool/APIData.h clang/lib/Tooling/DumpTool/A

[PATCH] D100712: [AST] Add NestedNameSpecifierLoc accessors to node introspection

2021-04-19 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/unittests/Introspection/IntrospectionTest.cpp:280 STRING_LOCATION_STDPAIR(MethodDecl, getTypeSpecStartLoc()) })); // clang-format on steveire wrote: > njames93 wrote: > > I'm not entirely sure on the case,

[PATCH] D100712: [AST] Add NestedNameSpecifierLoc accessors to node introspection

2021-04-19 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 338631. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D100712/new/ https://reviews.llvm.org/D100712 Files: clang/lib/Tooling/DumpTool/APIData.h clang/lib/Tooling/DumpTool/A

[PATCH] D93325: Add srcloc output to clang-query

2021-04-19 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. @aaron.ballman ping? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93325/new/ https://reviews.llvm.org/D93325 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lis

[PATCH] D100712: [AST] Add NestedNameSpecifierLoc accessors to node introspection

2021-04-22 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG21ce124e1e63: [AST] Add NestedNameSpecifierLoc accessors to node introspection (authored by stephenkelly). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D1007

[PATCH] D93988: [ASTMatchers] Make tests explicit about mode-dependence

2021-01-03 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D93988 Files: clang/unittests/ASTMatchers/

[PATCH] D93688: [ASTMatchers] Ensure that we can match inside lambdas

2021-01-04 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 314445. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93688/new/ https://reviews.llvm.org/D93688 Files: clang/include/clang/ASTMatchers/ASTMatchersInternal.h clang/lib/AST

[PATCH] D93688: [ASTMatchers] Ensure that we can match inside lambdas

2021-01-04 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 314446. steveire marked 2 inline comments as done. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93688/new/ https://reviews.llvm.org/D93688 Files: clang/include/clang/ASTMat

[PATCH] D93688: [ASTMatchers] Ensure that we can match inside lambdas

2021-01-04 Thread Stephen Kelly via Phabricator via cfe-commits
steveire marked an inline comment as done. steveire added inline comments. Comment at: clang/lib/ASTMatchers/ASTMatchFinder.cpp:526 +TraverseStmt(LE->getTrailingRequiresClause()); + +TraverseStmt(LE->getBody()); aaron.ballman wrote: > Do we also n

[PATCH] D93988: [ASTMatchers] Make tests explicit about mode-dependence

2021-01-04 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. In D93988#2477602 , @aaron.ballman wrote: > Could you give me a bit more background about why you want to make this > change? This change makes it explicit so that we can see which tests work in only one mode, and if we want t

[PATCH] D94029: [clang-tidy] Add extra tests

2021-01-04 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. Herald added a subscriber: xazax.hun. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. By default, check_clang_tidy runs tests in c++11-or-later mode. Repos

[PATCH] D94030: [ASTMatchers] Fix traversal matchers with explicit and defaulted methods

2021-01-04 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D94030 Files: clang/include/clang/ASTMatch

[PATCH] D94031: [ASTMatchers] Fix child traversal over range-for loops

2021-01-04 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D94031 Files: clang/lib/ASTMatchers/ASTMat

[PATCH] D94032: [ASTMatchers] Omit methods from explicit template instantations

2021-01-04 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D94032 Files: clang/lib/ASTMatchers/ASTMat

[PATCH] D93688: [ASTMatchers] Ensure that we can match inside lambdas

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGc3a21e5de3dc: [ASTMatchers] Ensure that we can match inside lambdas (authored by stephenkelly). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93688/new/ htt

[PATCH] D94030: [ASTMatchers] Fix traversal matchers with explicit and defaulted methods

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG7e4f53f748d3: [ASTMatchers] Fix traversal matchers with explicit and defaulted methods (authored by stephenkelly). Changed prior to commit: https:

[PATCH] D94030: [ASTMatchers] Fix traversal matchers with explicit and defaulted methods

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/include/clang/ASTMatchers/ASTMatchersInternal.h:727 + virtual bool IsMatchingChildrenNotSpelledInSource() const = 0; + virtual void SetMatchingChildrenNotSpelledInSource(bool Set) = 0; + aaron.ballman wrote: > W

[PATCH] D94029: [clang-tidy] Add extra tests

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG53c3acb89fcc: [clang-tidy] Add extra tests (authored by stephenkelly). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94029/new/ https://reviews.llvm.org/D94

[PATCH] D94032: [ASTMatchers] Omit methods from explicit template instantations

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGf22c0f40b5d6: [ASTMatchers] Omit methods from explicit template instantations (authored by stephenkelly). Changed prior to commit: https://reviews.llvm.org/D94032?vs=314451&id=314643#toc Repository:

[PATCH] D94031: [ASTMatchers] Fix child traversal over range-for loops

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/lib/ASTMatchers/ASTMatchFinder.cpp:245 +ScopedIncrement ScopedDepth(&CurrentDepth); +if (!match(*Node->getLoopVariable()) || !match(*Node->getRangeInit()) || +!match(*Node->getBody())) aaron.ballma

[PATCH] D94031: [ASTMatchers] Fix child traversal over range-for loops

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 314654. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94031/new/ https://reviews.llvm.org/D94031 Files: clang/lib/ASTMatchers/ASTMatchFinder.cpp clang/unittests/ASTMatcher

[PATCH] D94031: [ASTMatchers] Fix child traversal over range-for loops

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/lib/ASTMatchers/ASTMatchFinder.cpp:245 +ScopedIncrement ScopedDepth(&CurrentDepth); +if (!match(*Node->getLoopVariable()) || !match(*Node->getRangeInit()) || +!match(*Node->getBody())) aaron.ballma

[PATCH] D94031: [ASTMatchers] Fix child traversal over range-for loops

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG16c6e9c58e9a: [ASTMatchers] Fix child traversal over range-for loops (authored by stephenkelly). Repository: rG LLVM Github Monorepo CHANGES SINC

[PATCH] D94126: [ASTMatchers] Make it possible to use empty variadic matchers

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. When debugging a matcher it is convenient to be able to comment out nested matchers experimentally. This stop

[PATCH] D94127: [ASTMatchers] Add mapAnyOf matcher

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Make it possible to compose a matcher for different base nodes. This accepts one or more node matcher functo

[PATCH] D94128: [ASTMatchers] Make cxxOperatorCallExpr matchers API-compatible with n-ary operators

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This makes them composable with mapAnyOf(). Repository: rG LLVM Github Monorepo https://reviews.llvm.org

[PATCH] D94129: [ASTMatchers] Add binaryOperation matcher

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This is a simple utility which allows matching on binaryOperator and cxxOperatorCallExpr. It can also be exte

[PATCH] D94130: [ASTMatchers] Add support for CXXRewrittenBinaryOperator

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D94130 Files: clang/docs/LibASTMatchersRef

[PATCH] D94131: [clang-tidy] Use new mapAnyOf matcher

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. Herald added subscribers: kbarton, xazax.hun, nemanjai. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://review

[PATCH] D94127: [ASTMatchers] Add mapAnyOf matcher

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. This is part of a series of commits. See them in context here: https://github.com/steveire/llvm-project/commits/mapAnyOf Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94127/new/ https://reviews.llvm.org/D94127 __

[PATCH] D94131: [clang-tidy] Use new mapAnyOf matcher

2021-01-05 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 314739. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94131/new/ https://reviews.llvm.org/D94131 Files: clang-tools-extra/clang-tidy/bugprone/InfiniteLoopCheck.cpp clang-t

[PATCH] D94624: [PATCH] [clang-query] Add a --use-color option to clang-query

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. Can we make using color the default too? We already use colors for Decls I think, so this just adds colors for other Node types. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94624/new/ https://reviews.llvm.org/D94624 __

[PATCH] D94126: [ASTMatchers] Make it possible to use empty variadic matchers

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/lib/ASTMatchers/ASTMatchersInternal.cpp:402 ArrayRef InnerMatchers) { + if (InnerMatchers.empty()) +return true; aaron.ballman wrote: > Does it make sense to return `true`

[PATCH] D94624: [PATCH] [clang-query] Add a --use-color option to clang-query

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. I also don't think we need to add unit tests for this, just because we can. The tests would be more complex than the code and wouldn't add much value. https://softwareengineering.stackexchange.com/a/147342 There are lots of resources about this. Repository: rG LLVM

[PATCH] D94624: [PATCH] [clang-query] Add a --use-color option to clang-query

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang-tools-extra/clang-query/tool/ClangQuery.cpp:58 +standard output supports colors.)"), + cl::init(false), cl::cat(ClangQueryCategory)); + Doesn't this set the default to false? Repository: rG LLVM Gi

[PATCH] D94624: [PATCH] [clang-query] Add a --use-color option to clang-query

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang-tools-extra/clang-query/tool/ClangQuery.cpp:58 +standard output supports colors.)"), + cl::init(false), cl::cat(ClangQueryCategory)); + aaron.ballman wrote: > steveire wrote: > > Doesn't this set the d

[PATCH] D94624: [PATCH] [clang-query] Add a --use-color option to clang-query

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang-tools-extra/clang-query/tool/ClangQuery.cpp:58 +standard output supports colors.)"), + cl::init(false), cl::cat(ClangQueryCategory)); + tomrittervg wrote: > steveire wrote: > > aaron.ballman wrote: > >

[PATCH] D94624: [PATCH] [clang-query] Add a --use-color option to clang-query

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang-tools-extra/clang-query/tool/ClangQuery.cpp:58 +standard output supports colors.)"), + cl::init(false), cl::cat(ClangQueryCategory)); + tomrittervg wrote: > steveire wrote: > > tomrittervg wrote: > > >

[PATCH] D94126: [ASTMatchers] Make it possible to use empty variadic matchers

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/lib/ASTMatchers/ASTMatchersInternal.cpp:402 ArrayRef InnerMatchers) { + if (InnerMatchers.empty()) +return true; aaron.ballman wrote: > steveire wrote: > > aaron.ballman wr

[PATCH] D94126: [ASTMatchers] Make it possible to use empty variadic matchers

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire abandoned this revision. steveire added inline comments. Comment at: clang/lib/ASTMatchers/ASTMatchersInternal.cpp:402 ArrayRef InnerMatchers) { + if (InnerMatchers.empty()) +return true; aaron.ballman wrote: > st

[PATCH] D94127: [ASTMatchers] Add mapAnyOf matcher

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 316712. steveire added a comment. Changed the implementation a bit to make clang-query integration easier Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94127/new/ https://reviews.llvm.org/D94127 Files: clan

[PATCH] D94128: [ASTMatchers] Make cxxOperatorCallExpr matchers API-compatible with n-ary operators

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang/include/clang/ASTMatchers/ASTMatchersInternal.h:1994 + return None; +return FD->getNumParams() > 0 ? UO_PostInc : UO_PreInc; + } aaron.ballman wrote: > Not certain how much we want to care about it, but

[PATCH] D94128: [ASTMatchers] Make cxxOperatorCallExpr matchers API-compatible with n-ary operators

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 316743. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94128/new/ https://reviews.llvm.org/D94128 Files: clang/docs/LibASTMatchersReference.html clang/include/clang/ASTMatc

[PATCH] D94129: [ASTMatchers] Add binaryOperation matcher

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 316749. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94129/new/ https://reviews.llvm.org/D94129 Files: clang/docs/LibASTMatchersReference.html clang/docs/tools/dump_ast_m

[PATCH] D94130: [ASTMatchers] Add support for CXXRewrittenBinaryOperator

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 316751. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94130/new/ https://reviews.llvm.org/D94130 Files: clang/docs/LibASTMatchersReference.html clang/include/clang/AST/AST

[PATCH] D94130: [ASTMatchers] Add support for CXXRewrittenBinaryOperator

2021-01-14 Thread Stephen Kelly via Phabricator via cfe-commits
steveire marked an inline comment as done. steveire added inline comments. Comment at: clang/include/clang/ASTMatchers/ASTMatchers.h:5346 +AST_POLYMORPHIC_SUPPORTED_TYPES(BinaryOperator, CXXOperatorCallExpr, +CXXRewrittenBinaryOperator)) {

[PATCH] D94127: [ASTMatchers] Add mapAnyOf matcher

2021-01-16 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGa7101450a42e: [ASTMatchers] Add mapAnyOf matcher (authored by stephenkelly). Changed prior to commit: https://reviews.llvm.org/D94127?vs=316712&id

[PATCH] D94128: [ASTMatchers] Make cxxOperatorCallExpr matchers API-compatible with n-ary operators

2021-01-16 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGdbe056c2e37f: [ASTMatchers] Make cxxOperatorCallExpr matchers API-compatible with n-ary… (authored by stephenkelly). Changed prior to commit: http

[PATCH] D94129: [ASTMatchers] Add binaryOperation matcher

2021-01-16 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGe810e95e4bb9: [ASTMatchers] Add binaryOperation matcher (authored by stephenkelly). Changed prior to commit: https://reviews.llvm.org/D94129?vs=31

[PATCH] D94130: [ASTMatchers] Add support for CXXRewrittenBinaryOperator

2021-01-16 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGb765eaf9a617: [ASTMatchers] Add support for CXXRewrittenBinaryOperator (authored by stephenkelly). Changed prior to commit: https://reviews.llvm.o

[PATCH] D94864: [ASTMatchers] Re-order the internals to allow another use-case

2021-01-16 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Add an operator overload to ArgumentAdaptingMatcherFunc to allow use of mapAnyOf within hasAncestor, hasParen

[PATCH] D94865: [ASTMatchers] Add callOrConstruct matcher

2021-01-16 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D94865 Files: clang/docs/LibASTMatchersRef

[PATCH] D94131: [clang-tidy] Use new mapAnyOf matcher

2021-01-16 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 317177. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D94131/new/ https://reviews.llvm.org/D94131 Files: clang-tools-extra/clang-tidy/bugprone/InfiniteLoopCheck.cpp clang-t

[PATCH] D94876: Remove TypedMatcherOps from VariantValue

2021-01-17 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. It provides no features or advantage over ASTNodeKind-based handling. Repository: rG LLVM Github Monorepo

[PATCH] D94877: Add API to retrieve a clade kind from ASTNodeKind

2021-01-17 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D94877 Files: clang/include/clang/AST/ASTT

[PATCH] D94878: Make it possible to store a ASTNodeKind in VariantValue

2021-01-17 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D94878 Files: clang/include/clang/ASTMatch

<    5   6   7   8   9   10   11   >