This is an archive of the discontinued LLVM Phabricator instance.

[clang-tidy] Add -extra-arg and -extra-arg-before to run-clang-tidy.py
ClosedPublic

Authored by ehsan on Jan 4 2017, 4:36 PM.

Diff Detail

Repository
rL LLVM

Event Timeline

ehsan updated this revision to Diff 83165.Jan 4 2017, 4:36 PM
ehsan retitled this revision from to [clang-tidy] Add -extra-arg and -extra-arg-before to run-clang-tidy.py.
ehsan updated this object.
ehsan added reviewers: bkramer, alexfh, klimek.
ehsan added a subscriber: cfe-commits.
bkramer accepted this revision.Jan 13 2017, 5:31 AM
bkramer edited edge metadata.

This looks useful to me.

This revision is now accepted and ready to land.Jan 13 2017, 5:31 AM
alexfh added inline comments.Jan 14 2017, 3:02 AM
clang-tidy/tool/run-clang-tidy.py
80 ↗(On Diff #83165)

Why arg[0] and not just arg?

ehsan marked an inline comment as done.Jan 18 2017, 9:59 AM
ehsan added inline comments.
clang-tidy/tool/run-clang-tidy.py
80 ↗(On Diff #83165)

With nargs=1, extra_arg would be something like [['foo'], ['bar']] if -extra-arg foo -extra-arg bar is passed. But I realized that there is no good reason why I need nargs=1 since action='append' will make the arg parser consume one argument, so I'll remove that and simplify this to just arg.

This revision was automatically updated to reflect the committed changes.
ehsan marked an inline comment as done.