You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Implement separate set union and set intersection monoids (and semigroups) #363
For the intersection Monoid<Set<A>>, the zero would need to be the set of all values for that type , which would requires instance of Enumerator<A> (we have) and Bounded<A> (we don't have yet).
So this can be separated into two PRs if more manageable.
Hello, I would like to contribute. Can you explain, Why do I need to use Bounded<A> for intersection monoid zero, if Enumerator<A> can provide max and min elements?
max and min in Enumerator only return Option values and thus this is not very practical to instanciate the intersection Monoid. We could pass min and max explicitly though and not create Bounded for now.
Activity
jbgi commentedon Oct 2, 2018
👍 for the intersection Semigroup.
For the intersection
Monoid<Set<A>>, the zero would need to be the set of all values for that type , which would requires instance ofEnumerator<A>(we have) andBounded<A>(we don't have yet).So this can be separated into two PRs if more manageable.
toxyduck commentedon Oct 19, 2019
Hello, I would like to contribute. Can you explain, Why do I need to use
Bounded<A>for intersection monoid zero, ifEnumerator<A>can provide max and min elements?jbgi commentedon Oct 19, 2019
max and min in Enumerator only return Option values and thus this is not very practical to instanciate the intersection Monoid. We could pass min and max explicitly though and not create Bounded for now.