pub struct GroupPlan {
pub recursive: bool,
pub statics: Vec<StaticBinding>,
pub dynamics: Vec<DynamicBinding>,
pub inherit_froms: Vec<Expr>,
}Expand description
The normalized plan for one binding group — an attrset, a let, a rec,
or a legacy let { … }.
Fields§
§recursive: boolEffective recursiveness. The FIRST definition’s, never an OR of the
two — a later rec is discarded, which is what makes
{ a = {b=1;}; a = rec {c=2; d=c;}; } a parse error in nix.
statics: Vec<StaticBinding>Static bindings after the splice, in nix’s insertion order.
dynamics: Vec<DynamicBinding>Dynamic-keyed bindings. Collisions among these — and against
statics — are an EVAL-time error, and only when forced.
inherit_froms: Vec<Expr>One entry per inherit (e) …; clause that landed on this group,
INCLUDING clauses spliced in from a later side. Referenced by index
from Binding::InheritFrom so a clause’s source is evaluated once
and shared across its names.
Evaluated in the group’s OWN scope, which is rec-visible when the group
is recursive — measured: rec { b = {x=99;}; inherit (b) x; } is
x = 99, so the source sees the group it is being bound into.