Open frostburn opened 1 month ago
Requires immutable Fraction in xen-dev-utils and immutable Interval class etc.
Fraction
xen-dev-utils
Interval
New keyword immutable.
immutable
(* Immutable array expression *) let myTuple = immutable [1, 2, 3] (* Sugar for cost foo = immutable bar *) immutable myConstTuple = [4, 5] (* Only immutables can be nested inside other immutables *) immutable myNestedTuple = [0, myTuple, myConstTuple, [6, 7]] (* Variables with immutable values can be reassigned *) myTuple = (8,) (* Pythonic tuple syntax *)
Records:
immutable myConstImmutableRecord = {foo: 1, bar: 2} let myReassignableImmutableRecord = immutable {baz: 3, qux: {quux: 4, corge: 5}}
Requires immutable
Fraction
inxen-dev-utils
and immutableInterval
class etc.New keyword
immutable
.Records: