[PATCH] D36075: [refactor] Initial support for refactoring action rules

Alex Lorenz via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 28 03:48:10 PDT 2017

arphaman added a comment.


I'll start working on the documentation patch and will split follow-up `clang-refactor` patch into one or two parts today.

Comment at: include/clang/Tooling/Refactoring/RefactoringActionRulesInternal.h:33
+  virtual Expected<Optional<AtomicChanges>>
+  perform(RefactoringRuleContext &Context) = 0;
ioeric wrote:
> Why isn't this a interface in `SpecificRefactoringRuleAdapter` with return type `Expected<Optional<T>>`?
A method declaration in `SpecificRefactoringRuleAdapter` won't work since it won't be available in either the template specialisation or the deriving class as the classes won't be directly related. I could use a separate parent class independent of SpecificRefactoringRuleAdapter that declares a generic interface though.



More information about the cfe-commits mailing list