[PATCH] D66652: [libTooling] Transformer: refine `SourceLocation` specified as anchor of changes.

2019-09-27 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL373093: [libTooling] Transformer: refine `SourceLocation` specified as anchor of… (authored by ymandel, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior

[PATCH] D66652: [libTooling] Transformer: refine `SourceLocation` specified as anchor of changes.

2019-09-27 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel added a comment. In D66652#1654585 , @gribozavr wrote: > > So, I plan to rework this into two revisions: one to match > > https://reviews.llvm.org/D66676 (and keep the tests esssentially as they > > are) and one to add getRuleMatchLoc for future

[PATCH] D66652: [libTooling] Transformer: refine `SourceLocation` specified as anchor of changes.

2019-09-27 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 222177. ymandel added a comment. Herald added a subscriber: jfb. reworked to follow same scheme as clang-tidy version, per discussion. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D66652/new/ https://reviews.ll

[PATCH] D66652: [libTooling] Transformer: refine `SourceLocation` specified as anchor of changes.

2019-09-02 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr added a comment. > So, I plan to rework this into two revisions: one to match > https://reviews.llvm.org/D66676 (and keep the tests esssentially as they are) > and one to add getRuleMatchLoc for future use. That SGTM. I don't have an opinion about whether they should be separate revi

[PATCH] D66652: [libTooling] Transformer: refine `SourceLocation` specified as anchor of changes.

2019-08-27 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel added a comment. I'm having second thoughts about this -- I prefer the approach I ended up taking in https://reviews.llvm.org/D66676, which is subtly different. However, getRuleMatchLoc() will be useful a different purpose: when only reporting a diagnostic, with no corresponding changes

[PATCH] D66652: [libTooling] Transformer: refine `SourceLocation` specified as anchor of changes.

2019-08-23 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 216921. ymandel marked 2 inline comments as done. ymandel added a comment. comments tweaks. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D66652/new/ https://reviews.llvm.org/D66652 Files: clang/include/clang

[PATCH] D66652: [libTooling] Transformer: refine `SourceLocation` specified as anchor of changes.

2019-08-23 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr accepted this revision. gribozavr added inline comments. This revision is now accepted and ready to land. Comment at: clang/lib/Tooling/Refactoring/Transformer.cpp:197 // Verify the existence and validity of the AST node that roots this rule. + SourceLocation Root

[PATCH] D66652: [libTooling] Transformer: refine `SourceLocation` specified as anchor of changes.

2019-08-23 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 216838. ymandel added a comment. comment tweaks. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D66652/new/ https://reviews.llvm.org/D66652 Files: clang/include/clang/Tooling/Refactoring/Transformer.h clang/

[PATCH] D66652: [libTooling] Transformer: refine `SourceLocation` specified as anchor of changes.

2019-08-23 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel created this revision. ymandel added a reviewer: gribozavr. Herald added a project: clang. Every change triggered by a rewrite rule is anchored at a particular location in the source code. This patch refines how that location is chosen when the rule matches within a macro and defines it a