[clang-tools-extra] r349930 - [clang-tidy] Add export-fixes flag to clang-tidy-diff
Julie Hockett via cfe-commits
cfe-commits at lists.llvm.org
Fri Dec 21 09:25:27 PST 2018
Author: juliehockett
Date: Fri Dec 21 09:25:27 2018
New Revision: 349930
URL: http://llvm.org/viewvc/llvm-project?rev=349930&view=rev
Log:
[clang-tidy] Add export-fixes flag to clang-tidy-diff
Differential Revision: https://reviews.llvm.org/D55848
Modified:
clang-tools-extra/trunk/clang-tidy/tool/clang-tidy-diff.py
Modified: clang-tools-extra/trunk/clang-tidy/tool/clang-tidy-diff.py
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clang-tidy/tool/clang-tidy-diff.py?rev=349930&r1=349929&r2=349930&view=diff
==============================================================================
--- clang-tools-extra/trunk/clang-tidy/tool/clang-tidy-diff.py (original)
+++ clang-tools-extra/trunk/clang-tidy/tool/clang-tidy-diff.py Fri Dec 21 09:25:27 2018
@@ -57,6 +57,9 @@ def main():
default='')
parser.add_argument('-path', dest='build_path',
help='Path used to read a compile command database.')
+ parser.add_argument('-export-fixes', metavar='FILE', dest='export_fixes',
+ help='Create a yaml file to store suggested fixes in, '
+ 'which can be applied with clang-apply-replacements.')
parser.add_argument('-extra-arg', dest='extra_arg',
action='append', default=[],
help='Additional argument to append to the compiler '
@@ -122,6 +125,8 @@ def main():
command.append('-line-filter=' + quote + line_filter_json + quote)
if args.fix:
command.append('-fix')
+ if args.export_fixes:
+ command.append('-export-fixes=' + args.export_fixes)
if args.checks != '':
command.append('-checks=' + quote + args.checks + quote)
if args.quiet:
More information about the cfe-commits
mailing list