feat: add diagnostic system and improve CLI with check command

Implement comprehensive diagnostic reporting system:
- Add Diagnostic struct with severity levels and span-based error tracking
- Add diagnostic rendering with source context and caret positioning
- Replace ParseError with diagnostic collection in lexer and parser
- Add LexResult and ParseResult types to carry diagnostics

Enhance driver crate with frontend output:
- Replace CompileResult with FrontendOutput containing diagnostics
- Add has_errors() and render_diagnostics() methods
- Add AstSummary for
This commit is contained in:
2026-04-06 17:07:50 +02:00
parent 0da224325a
commit dfd2f10234
12 changed files with 1315 additions and 502 deletions

View File

@@ -5,6 +5,10 @@ edition.workspace = true
license.workspace = true
authors.workspace = true
[[bin]]
name = "nxc"
path = "src/main.rs"
[[bin]]
name = "nexacore"
path = "src/main.rs"