As a tangent I am interested in knowing what would be the typeclass for this sort of operation:
- take all the elements out of `f a`
- do something with them with a function a -> b
- insert the results back to get the same "original shape" `f b`
In this case "do something with them" is "order them" but it could also be
"invoke a function with all the 'a's and dispatch back the results" to allow "batching" function calls.
------------------------------------------------
Eric TORREBORRE
T +49 176 420 8383 4
E etorreborre@yahoo.com
P http://specs2.org
B http://etorreborre.blogspot.com
------------------------------------------------