clang-tools  14.0.0git
Classes | Public Attributes | List of all members
clang::clangd::config::Fragment::DiagnosticsBlock Struct Reference

Controls behavior of diagnostics (errors and warnings). More...

#include <ConfigFragment.h>

Collaboration diagram for clang::clangd::config::Fragment::DiagnosticsBlock:
Collaboration graph


struct  ClangTidyBlock
 Controls how clang-tidy will run over the code base. More...

Public Attributes

std::vector< Located< std::string > > Suppress
 Diagnostic codes that should be suppressed. More...
ClangTidyBlock ClangTidy

Detailed Description

Controls behavior of diagnostics (errors and warnings).

Definition at line 198 of file ConfigFragment.h.

Member Data Documentation

◆ ClangTidy

ClangTidyBlock clang::clangd::config::Fragment::DiagnosticsBlock::ClangTidy

Definition at line 234 of file ConfigFragment.h.

◆ Suppress

std::vector<Located<std::string> > clang::clangd::config::Fragment::DiagnosticsBlock::Suppress

Diagnostic codes that should be suppressed.

Valid values are:

  • *, to disable all diagnostics
  • diagnostic codes exposed by clangd (e.g unknown_type, -Wunused-result)
  • clang internal diagnostic codes (e.g. err_unknown_type)
  • warning categories (e.g. unused-result)
  • clang-tidy check names (e.g. bugprone-narrowing-conversions)

This is a simple filter. Diagnostics can be controlled in other ways (e.g. by disabling a clang-tidy check, or the -Wunused compile flag). This often has other advantages, such as skipping some analysis.

Definition at line 211 of file ConfigFragment.h.

The documentation for this struct was generated from the following file: