Files
Decodal/doc/manual/source/language/expression/composition.md
T

630 B

Composition Expression

A composition expression combines multiple values, constraints, or structures.

&

& performs constraint-preserving composition.

Port = Int & >= 1 & <= 65535;
Config = MyConfig & { port = 8000; };

Because object fields present on only one side are retained, & has no direction. Use as to verify that the left side is narrower than the right and treat the right side as the field domain.

//

// performs a right-biased structural patch.

Patched = Base // {
    feature_hoge.enable = false;
};

See Operators for details.