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
56
57
58
//! WORLD-4 — World Simulation (`inkhaven realworld` + the real-time
//! fact-checker). See `Documentation/PROPOSALS/WORLD-4_PLAN.md`.
//!
//! Branch A is a deterministic, layered, on-demand compiler that turns a
//! structured world definition (`world.hjson` + optional `world.bund`) into
//! populated system books. Five MVP layers run in dependency order —
//! astronomy → geology → climate → hydrology → demographics — each a pure
//! function of `(definition, seed)` (layer 5 has seeded-stochastic + AI parts).
//!
//! This module is built incrementally in the 1.3.x tree, one layer per signed
//! increment. **P0 ships the world-definition types and the astronomy layer**:
//! closed-form planetary physics (Kepler's third law, daily-insolation by
//! latitude band, lunar synodic periods, tides), with zero new dependencies.
//! Later phases add storage, materialization, the remaining layers, plakat, and
//! the fact-checker.
//!
//! Authority discipline (the spine of the RFC): the author always wins. The
//! compiler *proposes*; nothing commits without acceptance. Astronomy is the one
//! layer with no proposals — its outputs are closed-form physics, treated as
//! fact and re-asserted every run unless the author hand-overrides.
// Foundation ahead of its CLI / TUI / Bund consumers: the type/output API and
// its re-exports exist before the phases that will consume them.
use fmt;
/// The crate-local result type for world operations.
pub type Result<T> = Result;
/// Errors from parsing, validating, or compiling a world definition.