TextDiagnosticClient class
A diagnostic client that serializes diagnostics to human-friendly text format.
Base classes
- class DiagnosticClient
- A base class for diagnostic clients, which receive issued diagnostics and present them to the user in some form.
Derived classes
- class StderrDiagnosticClient
- A diagnostic client that serializes diagnostics to stderr.
Constructors, destructors, conversion operators
- TextDiagnosticClient()
- Constructs a new TextDiagnosticClient.
Public functions
- void showColors(bool show)
- Sets whether to use terminal color codes in the output.
- void showColumn(bool show)
- Sets whether to show column numbers in the output.
- void showLocation(bool show)
- Sets whether to show locations in the output.
- void showSourceLine(bool show)
- Sets whether to show source line context in the output.
- void showOptionName(bool show)
- Sets whether to show diagnostic option names in the output.
- void showIncludeStack(bool show)
- Sets whether to show include file stacks in the output.
- void showMacroExpansion(bool show)
- Sets whether to show macro expansions in the output.
- void showHierarchyInstance(ShowHierarchyPathOption option)
- Sets whether to show hierarchy paths in the output.
- TerminalColor getSeverityColor(DiagnosticSeverity severity) const
- Gets the terminal color to use for the given diagnostic severity.
- void report(const ReportedDiagnostic& diagnostic) override
- Called by the DiagnosticEngine to report a new diagnostic.
- void clear()
- Clears the serialized text buffer.
- bool empty() const
- Returns true if the text buffer is empty and false otherwise.
-
std::
string getString() const - Gets the current contents of the serialized text buffer.
Public variables
- TerminalColor noteColor
- The color to use for notes.
- TerminalColor warningColor
- The color to use for warnings.
- TerminalColor errorColor
- The color to use for errors.
- TerminalColor fatalColor
- The color to use for fatal errors.
- TerminalColor highlightColor
- The color to use for highlights.
- TerminalColor filenameColor
- The color to use for file names.
- TerminalColor locationColor
- The color to use for locations.