This extension integrates clang-tidy into VS Code.
Clang-Tidy documentation can be found here.
Runs clang-tidy and displays its diagnostics in VS Code.
Note: Diagnostics take longer to appear than in the example gif.
Clang-Tidy must be installed. The extension will look for the clang-tidy executable in your PATH
by default.
Clang-Tidy is part of LLVM, which can be downloaded here. Alternatively, use your system's package manager.
This extension contributes the following settings:
clang-tidy.executable
: The path to the clang-tidy executableclang-tidy.checks
: List of checks to enable or disableclang-tidy.compilerArgs
: List of arguments to append to the compiler command lineclang-tidy.compilerArgsBefore
: List of arguments to prepend to the compiler command lineclang-tidy.lintOnSave
: Whether or not to lint files when they are savedclang-tidy.buildPath
: Path to the build folder. Equivalent to clang-tidy -p /pathclang-tidy.fixOnSave
: Whether or not to fix files when they are savedclang-tidy.blacklist
: A list of regular expressions matching files you don't want to lint
This extension contributes the following commands:
Clang-Tidy: Lint File
: Lints the active file