034-parameterized-definitions
Parameterized definitions, variants and tenant profiles (amends 002 and 006)
An amendment of approved specs 002 and 006 (R-16), for #76 child B4. A definition may declare, as optional members this spec adds to the #76 track version `rustev.definition/2` (introduced by spec 032), typed, bounded parameters with lock levels (`fixed`, `bounded`, `free`), reference them from a closed set of literal positions, declare named variants and scope inputs, steps, handlers, rules and adjustments to them. A versioned profile document (`rustev.profile/1`) binds parameter values, may extend one other profile, and names its definition by a version range. Instantiation, a pure phase before compilation, resolves the range against the supplied definitions, resolves the overlay chain, checks every lock and bound, substitutes values and prunes the variant, yielding a definition without parameterization that the compiler compiles into a `rustev.plan/3` (the #76 track version, introduced by spec 032, to which this spec adds the optional member `instantiation`) whose `PlanId` binds the template, the variant, the profile chain and every resolved value. Adds `rustev plan diff` (`rustev.plan-diff/1`) and `rustev profile check`. A `rustev.definition/1` compiled without a profile still yields a byte-identical `rustev.plan/2` and `PlanId`. Approved (A-31); implementation is complete (see the implementation record).
Read the full pinned specification ↗Relationships
depends on
depended on by
amended by
Claimed units
- extends
{ "nature": "amending", "spec": "002-decision-contract-and-pure-core", "unit": { "kind": "directory", "path": "crates/rustev-contract/" } } - extends
{ "nature": "amending", "spec": "002-decision-contract-and-pure-core", "unit": { "kind": "directory", "path": "crates/rustev-core/" } } - extends
{ "nature": "additive", "spec": "004-evaluation-and-replay", "unit": { "kind": "directory", "path": "crates/rustev-eval/" } } - extends
{ "nature": "amending", "spec": "006-cli-surface", "unit": { "kind": "directory", "path": "crates/rustev-cli/" } } - extends
{ "nature": "additive", "spec": "031-public-api-and-release-family", "unit": { "kind": "directory", "path": "tools/rustev-release/" } } - extends
{ "nature": "additive", "spec": "027-node-and-wasm-bindings", "unit": { "kind": "directory", "path": "integrations/rustev-node/" } } - extends
{ "nature": "additive", "spec": "027-node-and-wasm-bindings", "unit": { "kind": "directory", "path": "integrations/rustev-wasm/" } } - extends
{ "nature": "additive", "spec": "027-node-and-wasm-bindings", "unit": { "kind": "directory", "path": "crates/rustev-surface/" } } - extends
{ "nature": "additive", "spec": "027-node-and-wasm-bindings", "unit": { "kind": "directory", "path": "tools/rustev-conformance/" } } - extends
{ "nature": "additive", "spec": "001-boundaries-and-authority", "unit": { "kind": "file", "path": "Makefile" } } - extends
{ "nature": "additive", "spec": "001-boundaries-and-authority", "unit": { "kind": "directory", "path": "scripts/acceptance/" } }
Source headings
- 034: Parameterized definitions, variants and tenant profiles (amends 002 and 006)
- 1. Purpose
- 2. Territory
- 2.1 Binding principles of #76
- 3. Behavior
- 3.1 Definition version 2
- 3.2 Parameter declarations
- 3.3 Parameter references
- 3.4 Variants and optional items
- 3.5 Profiles
- 3.6 Definition version binding
- 3.7 Overlay resolution
- 3.8 Instantiation
- 3.9 Instantiation refusals
- 3.10 Plan version 3 and identity
- 3.11 Loading, replay and evaluation
- 3.12 Plan diff
- 3.13 Profile check
- 3.14 CLI surface (amends spec 006)
- 3.15 Library surface
- 3.16 Compatibility
- 4. Out of scope
- 5. Observable negative cases
- Acceptance
- Verification
- Implementation record
- Decisions at approval
Frozen anchors
No frozen anchors declared.