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
//! Neovim snippet library (LuaSnip `from_vscode`-loadable package).
//!
//! Multi-file: LuaSnip's `from_vscode` loader reads a VS Code-style snippet
//! *package* — a `package.json` whose `contributes.snippets` points at one or
//! more snippet files, each in the VS Code snippet format. We emit both:
//!
//! - `editors/neovim/snippets/package.json` — the contribution manifest.
//! - `editors/neovim/snippets/eventb.json` — the snippets themselves, in the
//! exact same VS Code format the VS Code extension ships (rendered by
//! [`super::snippets_vscode`] so the two never drift).
//!
//! The hand-written Neovim setup loads this directory with
//! `require("luasnip.loaders.from_vscode").lazy_load { paths = { … } }`.
use ;
/// Render the `(relative path, content)` pairs for the Neovim snippet package.
/// The LuaSnip `from_vscode` contribution manifest. Mirrors the relevant
/// fields of a VS Code extension manifest: `contributes.snippets` maps the
/// `eventb` language to the sibling snippet file. Hand-laid (not `serde_json`,
/// whose default `Map` would sort keys alphabetically) for a deterministic,
/// declaration-ordered 2-space layout matching the snippet file.