Skip to main content

alpha2_diagnose/
lib.rs

1//! Format-neutral document diagnostics.
2//!
3//! A document is read into a [`Node`] tree that keeps where each value was in the text. Problems
4//! are [`Diagnostic`]s with a stable [`Code`], a [`Path`], a place, a message and, where it can be
5//! known, help and [`Fix`]es. A [`Report`] orders, groups and caps them for one document and
6//! renders them as text. Nothing here knows an alpha2 document type: the project and compose
7//! packs in `alpha2-model` and `alpha2-compose` bring their schemas, rules and judges.
8
9pub mod advise;
10pub mod codes;
11mod diagnostic;
12pub mod fix;
13mod path;
14pub mod read;
15pub mod render;
16mod report;
17pub mod run;
18pub mod schema;
19pub mod shape;
20pub mod suggest;
21mod tree;
22pub mod write;
23
24pub use diagnostic::{
25    Applicability, Code, Collector, Diagnostic, Edit, Fix, REVIEW_PREFIX, Reference, Severity,
26};
27pub use path::{Path, PathError, Segment};
28#[cfg(feature = "schema")]
29pub use report::report_json_schema;
30pub use report::{
31    Counts, DEFAULT_LIMIT, MAX_ALSO, MAX_EXCERPT_BYTES, Options, REPORT_SCHEMA_ID, Report, excerpt,
32    group, order,
33};
34pub use tree::{Entry, Node, Number, NumberKind, Span, Value};