[PATCH] D61335: [LibTooling] Add support to Transformer for composing rules as an ordered choice.
Yitzhak Mandelbaum via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Apr 30 12:52:23 PDT 2019
ymandel created this revision.
ymandel added a reviewer: ilya-biryukov.
Herald added a project: clang.
This revision adds a new kind of rewrite rule, `CompositeRewriteRule`, which
composes multiple subrules into a new rule that allows ordered-choice among its
subrules. With this feature, users can write the rules that appear later in the
list of subrules knowing that previous rules' patterns *have not matched*,
freeing them from reasoning about those cases in the current pattern.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D61335
Files:
clang/include/clang/Tooling/Refactoring/Transformer.h
clang/lib/Tooling/Refactoring/Transformer.cpp
clang/unittests/Tooling/TransformerTest.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D61335.197418.patch
Type: text/x-patch
Size: 10096 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190430/8ddf2b69/attachment.bin>
More information about the cfe-commits
mailing list