/**
 * Diagnostic types for Tsonic compiler
 */
/**
 * Diagnostic severity levels.
 *
 * - fatal: Unrecoverable error that aborts compilation (e.g., missing stdlib type)
 * - error: Recoverable error that prevents code generation but allows continued analysis
 * - warning: Non-blocking issue that should be addressed
 * - info: Informational message
 */
export type DiagnosticSeverity = "fatal" | "error" | "warning" | "info";
export type DiagnosticCode = "TSN1001" | "TSN1002" | "TSN1003" | "TSN1004" | "TSN1005" | "TSN1006" | "TSN2001" | "TSN2002" | "TSN2003" | "TSN2004" | "TSN3001" | "TSN3002" | "TSN3003" | "TSN3011" | "TSN4001" | "TSN4002" | "TSN4003" | "TSN4004" | "TSN4005" | "TSN4006" | "TSN4007" | "TSN5001" | "TSN5002" | "TSN6001" | "TSN6201" | "TSN6202" | "TSN6203" | "TSN6204" | "TSN7101" | "TSN7102" | "TSN7103" | "TSN7104" | "TSN7105" | "TSN7106" | "TSN7201" | "TSN7203" | "TSN7204" | "TSN7301" | "TSN7401" | "TSN7402" | "TSN7403" | "TSN7405" | "TSN7406" | "TSN7407" | "TSN7408" | "TSN7409" | "TSN7410" | "TSN7413" | "TSN7414" | "TSN7415" | "TSN7416" | "TSN7417" | "TSN7418" | "TSN7419" | "TSN7421" | "TSN7422" | "TSN7423" | "TSN7430" | "TSN7431" | "TSN7432" | "TSN7440" | "TSN7441" | "TSN7442" | "TSN7443" | "TSN7444" | "TSN9001" | "TSN9002" | "TSN9003" | "TSN9004" | "TSN9005" | "TSN9006" | "TSN9007" | "TSN9008" | "TSN9009" | "TSN9010" | "TSN9011" | "TSN9012" | "TSN9013" | "TSN9014" | "TSN9015" | "TSN9016" | "TSN9017" | "TSN9018" | "TSN9101" | "TSN9102" | "TSN9103" | "TSN9104" | "TSN9105" | "TSN9106" | "TSN9107" | "TSN9108" | "TSN9109" | "TSN9110" | "TSN9111" | "TSN9112" | "TSN9113" | "TSN9114" | "TSN5101" | "TSN5102" | "TSN5103" | "TSN5104" | "TSN5105" | "TSN5106" | "TSN5107" | "TSN5108" | "TSN5109" | "TSN5110" | "TSN5201" | "TSN5202" | "TSN5203" | "TSN6101";
export type SourceLocation = {
    readonly file: string;
    readonly line: number;
    readonly column: number;
    readonly length: number;
};
export type Diagnostic = {
    readonly code: DiagnosticCode;
    readonly severity: DiagnosticSeverity;
    readonly message: string;
    readonly location?: SourceLocation;
    readonly hint?: string;
    readonly relatedLocations?: readonly SourceLocation[];
};
export declare const createDiagnostic: (code: DiagnosticCode, severity: DiagnosticSeverity, message: string, location?: SourceLocation, hint?: string, relatedLocations?: readonly SourceLocation[]) => Diagnostic;
export declare const isError: (diagnostic: Diagnostic) => boolean;
export declare const isFatal: (diagnostic: Diagnostic) => boolean;
export declare const formatDiagnostic: (diagnostic: Diagnostic) => string;
export type DiagnosticsCollector = {
    readonly diagnostics: readonly Diagnostic[];
    readonly hasErrors: boolean;
    readonly hasFatalErrors: boolean;
};
export declare const createDiagnosticsCollector: () => DiagnosticsCollector;
export declare const addDiagnostic: (collector: DiagnosticsCollector, diagnostic: Diagnostic) => DiagnosticsCollector;
export declare const mergeDiagnostics: (collector1: DiagnosticsCollector, collector2: DiagnosticsCollector) => DiagnosticsCollector;
//# sourceMappingURL=diagnostic.d.ts.map