Expand description
§Error Handling
Error types and diagnostics for parsing and rendering, with source location tracking.
§Document path anchors
A Diagnostic carries two independent “where” anchors, both optional:
Diagnostic::location: source-text anchor (file:line:column). Produced by parsers and backend compilers operating on raw text.Diagnostic::path: document-model anchor into the typedcrate::document::Document. Produced by schema validation and coercion, which run on the typed model after line spans are gone.
DocPath is the one type that constructs, renders,
and parses the path, no site assembles one with format!. Its module doc
carries the grammar; prose/canon/ERROR.md tabulates the anchors.
Re-exports§
pub use crate::document::limits::MAX_YAML_DEPTH;
Structs§
- Diagnostic
- Structured diagnostic information.
- Location
- Render
Error - Main error type for rendering operations: a non-empty collection of
Diagnostics. - Render
Result - Yaml
Error - A YAML parse or emit failure, owned by this crate.
Enums§
- Parse
Error - Severity
- Fatality is this two-value ladder and nothing else:
Errorblocks the stage that emits it,Warningnever does. There is no lint-level configuration and no warning-to-error promotion; an informational aside is aDiagnostic::hint, not a severity.
Constants§
- MAX_
CARD_ COUNT - Maximum number of card blocks allowed per document
- MAX_
FIELD_ COUNT - Maximum number of fields allowed per document
- MAX_
INPUT_ SIZE - Maximum input size for markdown (10 MiB)
- MAX_
NESTING_ DEPTH - Maximum nesting depth for markdown structures (100 levels). Owned by the
markdown codecs in
quillmark-content(the import guard) and re-exported here so the typst backend’s markup converter shares one limit: a document that imports also renders, and vice versa. Maximum container nesting depth the markdown codecs accept before erroring. The import guard (import::from_markdown) and the typst backend’s markup converter share this one limit (the backend re-exports it viaquillmark_core::error::MAX_NESTING_DEPTH), so a document that imports also renders. - MAX_
YAML_ SIZE - Maximum YAML size (1 MiB)