
17 Apr
2014
17 Apr
'14
7:32 p.m.
Can we argue about the fixity for (<&>)? I've always it as infixl 4, to mix it in with other applicative operators, e.g.:
(:) <$> fx <*> fl
becomes
fx <&> (:) <*> fl
I agree, this seems to be a mistake in lens.
Last I checked,
(&) = flip ($)
is both shorter to type, and more explicit than:
import Control.Apply.Reverse
- Clark
Well the purpose here is to propose a standard name and fixity, not to save keystrokes. When a lot of libraries start to define a (trivial) thing under different names, that to me is a good indication that it should be in the standard library. It is a matter of keeping the signal-to-noise ratio large, which greatly helps when reading unfamiliar code. Hans