validator.vim icon indicating copy to clipboard operation
validator.vim copied to clipboard

Correct command line of clang-tidy

Open petersohn opened this issue 8 years ago • 2 comments

The command line should be clang-tidy <options> -- filename, not clang-tidy filename -- <options>.

petersohn avatar Mar 19 '17 12:03 petersohn

The arguments after -- should be compilation options.

http://clang.llvm.org/extra/clang-tidy/#using-clang-tidy

maralla avatar Mar 20 '17 02:03 maralla

Yes, they are compilation options, not clang-tidy options. (clang-tidy --tidy-options source.file -- compilation_options), also running clang-tidy from /tmp means it can't use its own configuration files nor compile_commands.json in the current working directory.

mistotebe avatar Nov 11 '20 16:11 mistotebe