forked from qt-creator/qt-creator
ClangTools: Allow to disable a specific type of diagnostic
... from the results list. This is much more convenient for the user than having to locate the diagnostic in the settings first. This patch deals with the global settings. We plan to offer the same for project-level settings in a follow-up patch. Task-number: QTCREATORBUG-24852 Change-Id: I7a97189c393048b98b9c2cdb6f21861a34670e8f Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -256,6 +256,11 @@ QString clazyStandaloneExecutable()
|
||||
}
|
||||
|
||||
static void addBuiltinConfigs(ClangDiagnosticConfigsModel &model)
|
||||
{
|
||||
model.appendOrUpdate(builtinConfig());
|
||||
}
|
||||
|
||||
ClangDiagnosticConfig builtinConfig()
|
||||
{
|
||||
ClangDiagnosticConfig config;
|
||||
config.setId(Constants::DIAG_CONFIG_TIDY_AND_CLAZY);
|
||||
@@ -265,8 +270,7 @@ static void addBuiltinConfigs(ClangDiagnosticConfigsModel &model)
|
||||
config.setClangOptions({"-w"}); // Do not emit any clang-only warnings
|
||||
config.setClangTidyMode(ClangDiagnosticConfig::TidyMode::UseDefaultChecks);
|
||||
config.setClazyMode(ClangDiagnosticConfig::ClazyMode::UseDefaultChecks);
|
||||
|
||||
model.appendOrUpdate(config);
|
||||
return config;
|
||||
}
|
||||
|
||||
ClangDiagnosticConfigsModel diagnosticConfigsModel(const ClangDiagnosticConfigs &customConfigs)
|
||||
|
||||
Reference in New Issue
Block a user