|
| struct diag_engine * | diag_engine_new (const char *filename, const char *source, long source_len) |
| | Create a new diagnostic engine.
|
| |
|
void | diag_engine_free (struct diag_engine *engine) |
| | Free a diagnostic engine and all its entries.
|
| |
| void | diag_emit (struct diag_engine *engine, enum diag_severity severity, int line, int col, const char *fmt,...) DIAG_PRINTF_FORMAT(5 |
| | Emit a diagnostic message.
|
| |
|
void void | diag_print_all (struct diag_engine *engine, FILE *stream) |
| | Print all accumulated diagnostics to a stream. Uses ANSI colors if stream is a terminal.
|
| |
|
int | diag_has_errors (struct diag_engine *engine) |
| | Check if any errors were emitted.
|
| |
|
int | diag_error_count (struct diag_engine *engine) |
| | Get the number of errors emitted.
|
| |
Diagnostic engine for clang-style error reporting.
Provides structured diagnostics with:
- clang-style format: filename:line:col: severity: message
- Source code snippet with caret indicator
- Severity levels (error, warning, note)
- ANSI color output (auto-detected via isatty)