[Haskell-cafe] avoiding parens in postfix applicative notation

Johannes Waldmann johannes.waldmann at htwk-leipzig.de
Wed Feb 7 09:02:03 UTC 2018


Thanks for comments and suggestions.


> The lens library defines (<&>) with very low precedence

Yes. I guess my question was: Why?


> f <$> foo <*> bar where f x y = ...

I avoid "where" because

* it uses an identifier before it is defined

* it is not as composable as "let", which is an
  expression, but "where" can only be attached to
  declarations - I can write  1 + let x = 3 in x
  but not  1 + ( x where x = 3 )

- J.W.


More information about the Haskell-Cafe mailing list