1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
//! # lima
//!
//! **LIMA Is Metadata Annotation** — a small, predictable frontmatter
//! parser. A deliberate, focused subset of YAML: the part frontmatter
//! actually needs, with well-defined types, no surprises, and zero runtime
//! dependencies.
//!
//! ```
//! use lima::{parse, ParseOptions};
//!
//! let result = parse(
//! "title: Hello World\npublished: 2024-03-01\ndraft: false\n",
//! ParseOptions::default(),
//! ).unwrap();
//! ```
//!
//! [`parse_core`] implements Lima Core 1.2 in full (block/flow sequences
//! and mappings, dates, numbers, quoting, `|` literal block scalars).
//! [`parse`] implements References 2.1 on top of it. [`parse_references`]
//! remains as a deprecated alias with identical 2.1 semantics.
//!
//! See <https://limaformat.dev> for the specification, and the
//! TypeScript implementation (`@limaformat/lima` on npm) for a second,
//! independently maintained reference.
//!
//! ## Conformance
//!
//! Checked against the shared, language-neutral conformance corpus through
//! Lima Core 1.2 and References 2.1 (including the additive 1.2/2.1 suites),
//! plus the frozen References 1.0 corpus. The Core 1.0/1.1 and References 1.0
//! baselines remain count- and hash-pinned by their corpus manifests.
pub use crate;
pub use crateDiagnostic;
pub use crate;