[cfe-users] How to use clang-apply-replacements with clang-tidy fixit file

Christian Gagneraud via cfe-users cfe-users at lists.llvm.org
Fri Apr 26 13:37:59 PDT 2019

On Sat, 27 Apr 2019 at 07:20, Robert Ankeney via cfe-users
<cfe-users at lists.llvm.org> wrote:
> I used clang-tidy to generate some replacements for a code base into a yaml file using the -export-fixits=file option. After editing the file to remove some unwanted changes, I would like to apply those fixes. The documentation says to use clang-apply-replacements, but I don't see how do use it to do that. It looks more like it's designed to work with clang-format. Any suggestions?

If you don't care about formatting the post-replacement code with
clang format, just run "clang-apply-replacements /path/to/source/dir'.
It will scan for '.yml' files, and apply all replacements.


> Many thanks,
> Robert
> _______________________________________________
> cfe-users mailing list
> cfe-users at lists.llvm.org
> https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-users

More information about the cfe-users mailing list