Get the latest tech news
Overloading the lambda abstraction in Haskell (2022)
my personal web space, for your enjoyment
There are solutions to this, like the great overloaded package, that fixes the proc notation and crucially makes it available to many categories that are not Arrow s. This may very well be exactly what you — the reader — need to resolve this problem. Now to allow more stuff than just composing morphisms as functions, more primitives can be added, like pair using(&&&), and unit using Void :: Flow a () — which may or may not be available, dependending on the kind of categories you’re working with. Therefore there is no need to clutter the syntax with<$>,>>=, pure,-<, returnA and a bind for every single arrow like in the proc notation: you just compose and apply them like regular functions — even when they are effectful.
Or read this on Hacker News