Releases: salt-die/mind_the_gaps
Releases · salt-die/mind_the_gaps
Removed `Gap.__invert__()` and made `Var` public.
Gap.__invert__
makes poor assumptions about the bounds of a Gaps generic type. It's better not to make any assumptions and remove this operator. PositiveInfinity
and NegativeInfinity
are also removed with this change. Gaps can still be inverted "by hand", e.g. my_gaps ^ Gaps([some_smallest_value < x, x < some_largest_value])
.
Var
is now public. Useful if x
is already in your namespace.
Create gaps from strings or from `x`.
Create gaps from a string or from x
, e.g.,
>>> from mind_the_gaps import Gaps, x
>>> 0 <= x
Endpoint(value=0, boundary='[')
>>> x < 1
Endpoint(value=1, boundary=')')
>>> print(Gaps([0 <= x, x < 1]))
{[0, 1)}
>>> print(Gaps.from_string("{[0, 1)}"))
{[0, 1)}
Initial alpha release.
Mind the gaps!
Gaps are sets of mutually exclusive sorted intervals that can be union-ed, intersected, xor-ed, or subtract-ed.