|
clang 24.0.0git
|
Defines the Diagnostic-related interfaces. More...
#include "clang/Basic/DiagnosticIDs.h"#include "clang/Basic/DiagnosticOptions.h"#include "clang/Basic/OptionalUnsigned.h"#include "clang/Basic/SourceLocation.h"#include "clang/Basic/Specifiers.h"#include "llvm/ADT/ArrayRef.h"#include "llvm/ADT/DenseMap.h"#include "llvm/ADT/FunctionExtras.h"#include "llvm/ADT/IntrusiveRefCntPtr.h"#include "llvm/ADT/SmallString.h"#include "llvm/ADT/SmallVector.h"#include "llvm/ADT/StringExtras.h"#include "llvm/ADT/iterator_range.h"#include "llvm/Support/Compiler.h"#include "llvm/Support/ConvertUTF.h"#include "llvm/Support/VirtualFileSystemFwd.h"#include <cassert>#include <cstdint>#include <limits>#include <list>#include <map>#include <memory>#include <optional>#include <string>#include <string_view>#include <type_traits>#include <utility>#include <vector>Go to the source code of this file.
Classes | |
| class | clang::FixItHint |
| Annotates a diagnostic with some code that should be inserted, removed, or replaced to fix the problem. More... | |
| struct | clang::DiagnosticStorage |
| class | clang::DiagStorageAllocator |
| An allocator for DiagnosticStorage objects, which uses a small cache to objects, used to reduce malloc()/free() traffic for partial diagnostics. More... | |
| class | clang::DiagnosticsEngine |
| Concrete class used by the front-end to report problems and issues. More... | |
| class | clang::DiagnosticErrorTrap |
| RAII class that determines when any errors have occurred between the time the instance was created and the time it was queried. More... | |
| class | clang::IgnoreAllWarningDiagRAII |
| RAII class that temporarily sets the "ignore all warnings" state on a DiagnosticsEngine and restores the previous state on destruction. More... | |
| class | clang::ForceSystemWarningsRAII |
| RAII class that temporarily forces warnings in system headers and system macros to be shown on a DiagnosticsEngine and restores the previous state on destruction. More... | |
| class | clang::StreamingDiagnostic |
| The streaming interface shared between DiagnosticBuilder and PartialDiagnostic. More... | |
| class | clang::DiagnosticBuilder |
| A little helper class used to produce diagnostics. More... | |
| struct | clang::AddFlagValue |
| class | clang::Diagnostic |
| A little helper class (which is basically a smart pointer that forwards info from DiagnosticsEngine and DiagnosticStorage) that allows clients to enquire about the diagnostic. More... | |
| class | clang::StoredDiagnostic |
| Represents a diagnostic in a form that can be retained until its corresponding source manager is destroyed. More... | |
| class | clang::DiagnosticConsumer |
| Abstract interface, implemented by clients of the front-end, which formats and prints fully processed diagnostics. More... | |
| class | clang::IgnoringDiagConsumer |
| A diagnostic client that ignores all diagnostics. More... | |
| class | clang::ForwardingDiagnosticConsumer |
| Diagnostic consumer that forwards diagnostics along to an existing, already-initialized diagnostic consumer. More... | |
| struct | clang::TemplateDiffTypes |
Namespaces | |
| namespace | llvm |
| Diagnostic wrappers for TextAPI types for error reporting. | |
| namespace | clang |
| Top level wrappers for InstallAPI frontend operations. | |
| namespace | clang::tok |
Typedefs | |
| using | clang::DiagNullabilityKind = std::pair<NullabilityKind, bool> |
| A nullability kind paired with a bit indicating whether it used a context-sensitive keyword. | |
Enumerations | |
| enum class | clang::DiagStateSystemClass : unsigned { clang::UserCode = 0 , clang::SystemMacro = 1 << 0 , clang::SystemHeader = 1 << 1 , clang::SystemHeaderAndMacro = SystemHeader | SystemMacro , clang::NUM_CLASSES } |
| Whether a source location is in a system header and/or a system macro. More... | |
Functions | |
| const DiagnosticBuilder & | clang::operator<< (const DiagnosticBuilder &DB, const AddFlagValue V) |
| Register a value for the flag in the current diagnostic. | |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, StringRef S) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const llvm::Twine &S) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, std::string_view S) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const std::string &S) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const llvm::SmallVectorImpl< char > &S) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const char *Str) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const llvm::APSInt &Int) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const llvm::APInt &Int) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, int I) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, long I) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, long long I) |
| template<typename T> | |
| std::enable_if_t< std::is_same< T, bool >::value, const StreamingDiagnostic & > | clang::operator<< (const StreamingDiagnostic &DB, T I) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, unsigned I) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, unsigned long I) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, unsigned long long I) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, tok::TokenKind I) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const IdentifierInfo *II) |
| template<typename T> | |
| std::enable_if_t< std::is_same< std::remove_const_t< T >, DeclContext >::value, const StreamingDiagnostic & > | clang::operator<< (const StreamingDiagnostic &DB, T *DC) |
| template<typename T, typename U, typename UnderlyingU = typename std::enable_if_t< std::is_enum_v<std::remove_reference_t<U>>, std::underlying_type<std::remove_reference_t<U>>>::type> | |
| std::enable_if_t< std::is_same_v< std::remove_const_t< T >, StreamingDiagnostic > &&!std::is_convertible_v< U, UnderlyingU >, const StreamingDiagnostic & > | clang::operator<< (const T &DB, U &&SE) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, SourceLocation L) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, SourceRange R) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, ArrayRef< SourceRange > Ranges) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const CharSourceRange &R) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const FixItHint &Hint) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, ArrayRef< FixItHint > Hints) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const std::optional< SourceRange > &Opt) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const std::optional< CharSourceRange > &Opt) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, const std::optional< FixItHint > &Opt) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, DiagNullabilityKind nullability) |
| const StreamingDiagnostic & | clang::operator<< (const StreamingDiagnostic &DB, llvm::Error &&E) |
| llvm::raw_ostream & | clang::operator<< (llvm::raw_ostream &OS, const StoredDiagnostic &) |
| void | clang::ProcessWarningOptions (DiagnosticsEngine &Diags, const DiagnosticOptions &Opts, llvm::vfs::FileSystem &VFS, bool ReportDiags=true) |
| ProcessWarningOptions - Initialize the diagnostic client and process the warning options specified on the command line. | |
| void | clang::EscapeStringForDiagnostic (StringRef Str, SmallVectorImpl< char > &OutStr) |
| EscapeStringForDiagnostic - Append Str to the diagnostic buffer, escaping non-printable characters and ill-formed code unit sequences. | |
| SmallString< 16 > | clang::EscapeSingleCodepointForDiagnostic (StringRef Str) |
| Displays a single Unicode codepoint in U+NNNN notation, optionally prepending the quoted codepoint itself if printable. | |
| SmallString< 16 > | clang::EscapeSingleCodepointForDiagnostic (llvm::UTF32 CP) |
Variables | |
| const char | clang::ToggleHighlight = 127 |
| Special character that the diagnostic printer will use to toggle the bold attribute. | |
Defines the Diagnostic-related interfaces.
Definition in file Diagnostic.h.