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
I have to apologize in advance, I don't have too much time to explain this or how I got here, but basically:
Functor is to Contravariant what Applicative is to Divisible
Traversable is to Applicative what Contraversable is to Divisible
It looks like you can only give instances of Contraversable for functors that are isomorphic to Vec n for some n
This sucks
Lax monoidal contravariant functors that cohere tupling with Smash form a Smashable subclass of Divisible
Divisible is to Contraversable what Smashable is to "Schmaversable", which would form a superclass of Contraversable
Schamversables at last allow us to comprehend variable sized containers
You can fill a Schmaversable container with piecewise comprehensions/predicates/folds/whatever Smashable contravariant thing you like
When you schmaverse the container, of type t (p a), the resulting p (t a) represents a comprehension/predicate/fold/whatever that acts only on containers of agreeable shape.
I'll hopefully come back and flesh this out, but in the meantime, some code:
I have to apologize in advance, I don't have too much time to explain this or how I got here, but basically:
Functor
is toContravariant
whatApplicative
is toDivisible
Traversable
is toApplicative
whatContraversable
is toDivisible
Contraversable
for functors that are isomorphic toVec n
for somen
Smash
form aSmashable
subclass ofDivisible
Divisible
is toContraversable
whatSmashable
is to "Schmaversable
", which would form a superclass ofContraversable
Schamversable
s at last allow us to comprehend variable sized containersSchmaversable
container with piecewise comprehensions/predicates/folds/whateverSmashable
contravariant thing you likeschmaverse
the container, of typet (p a)
, the resultingp (t a)
represents a comprehension/predicate/fold/whatever that acts only on containers of agreeable shape.I'll hopefully come back and flesh this out, but in the meantime, some code:
The text was updated successfully, but these errors were encountered: