Skip to main content

foch_annotation/
lib.rs

1//! Foch annotations: extra meaning carried in EU4 script comments.
2//!
3//! An annotation such as `#test(time=1444.11.11, tag=SWE)` is an ordinary
4//! comment to the game, so an annotated mod stays a valid mod that EU4 loads
5//! without any Foch step. This crate only reads annotations; it never changes
6//! script that the game loads. Extensions that need compiling into native
7//! script belong elsewhere.
8//!
9//! Each annotation is described by an [`AnnotationSchema`](schema::AnnotationSchema),
10//! plain data that drives validation, completion, hover and help alike.
11//! Consumers such as the test runner give annotations their meaning; editors
12//! need only this crate.
13
14pub mod builtin;
15pub mod diagnostic;
16pub mod editor;
17pub mod extract;
18pub mod schema;
19pub mod source;
20pub mod value;
21
22pub use diagnostic::{Code, Diagnostic, Severity};
23pub use extract::{Annotation, Applied, Attachment, Extraction, Target, extract, extract_parsed};
24pub use schema::{AnnotationSchema, Registry};