Gabriella439 / pipes-concurrency

Concurrency for the pipes ecosystem
BSD 3-Clause "New" or "Revised" License
43 stars 12 forks source link

Contravariant instance for Output #25

Closed bens closed 4 years ago

bens commented 10 years ago

It would require adding a dependency on the contravariant package, but it would give symmetry with instance Functor Input and I wouldn't need an orphan instance then. Just a suggestion.

instance Contravariant Output where
  contramap f (Output m) = Output (m . f)
Gabriella439 commented 10 years ago

pipes-concurrency is a package that I'd like to get into the Haskell Platform eventually, or at least get the pipes-independent subset of this package into the Haskell Platform. So my policy on this is to not add a contravariant dependency until contravariant gets into the Haskell platform.

However, I'll keep this issue open as a reminder to myself to bug Edward about getting contravariant into the Haskell Platform. I'm slowly wearing away at him to start merging some of his libraries into there.

bens commented 10 years ago

No problem, that's perfectly reasonable.

bens commented 4 years ago

This was implemented at some point, so I'll close the issue.