Skip to main content

Diagnostics

Diagnostic model and code ranges

Jazz uses one structured diagnostic model for errors and warnings. Reports carry effective severity, a stable code, origin, summary, source labels, notes, and help. Warning promotion changes severity but keeps the W#### code and does not duplicate the report.

RangeSubsystem
E0001E0005syntax and Prelude preparation
E1001E1010name and semantic analysis
E2001E2019type inference and checking
E3001E3040runtime evaluation and host operations
E4001E4016module resolution, imports, and exports
E5001E5005CLI, configuration, source input, and profiles

Pattern coverage uses two strict type diagnostics:

CodeMeaning
E2018a case or pattern lambda is non-exhaustive; the summary gives a witness
E2019an entire arm is unreachable after earlier unguarded arms

Guarded arms never contribute to exhaustiveness or shadow later arms. A guarded arm is still checked for reachability, so earlier unguarded arms can make it report E2019. Existing analysis or type errors suppress pattern-coverage follow-on reports.

Warning categories and IDs

The warning catalog is:

CodeTokenStatus
W0001same-scope-rebindingemitted when enabled
W0002shadowing-outer-scopeemitted when enabled
W0003unused-bindingemitted for ordinary lexical-block bindings when enabled
W0004deprecated-syntaxreserved; no analyzer emitter

Warnings are off by default. Syntax rejected by the parser is an error, not a deprecation warning. CLI, environment, and config selection are described in the CLI reference.

Output and severity

Standalone spans render as line:column; resolved module spans include the source path. Cross-module diagnostics can carry related locations. Compile errors suppress evaluation. Runtime errors suppress the final rendered value; warning-only runs still evaluate.