Ticket #4189 (closed proposal: wontfix)
(<.>) operator (generalizing (.) to Functor)
| Reported by: | uzytkownik | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | Not GHC |
| Component: | libraries/base | Version: | 6.12.3 |
| Keywords: | Cc: | ||
| Operating System: | Unknown/Multiple | Architecture: | Unknown/Multiple |
| Type of failure: | None/Unknown | Difficulty: | |
| Test Case: | Blocked By: | ||
| Blocking: | Related Tickets: |
Description
Currently there are following operators:
(<$>) :: (a -> b) -> f a -> f b ($) :: (a -> b) -> a -> b (.) :: (b -> c) -> (a -> b) -> a -> c
However defining the operator that is to <$> as . is to $ is trivial:
(<.>) :: (b -> c) -> (a -> f b) -> a -> f c f <.> g = fmap f . g
It would help writing in pointless style using Functors (as well as Applicatives/Monads etc.)
Attachments
Change History
Note: See
TracTickets for help on using
tickets.

