Confusing documentation of <**>
Location of documentation issue: the Haddocks of
The Haddock documentation of (<**>) is very brief, it simply says:
A variant of '<*>' with the arguments reversed.
For me this is too brief. It makes it sound like
(<**>) = flip (<*>), which is not true for all applicatives, e.g.:
ghci> (<**>) (print 1) (id <$ print 2) 1 2 ghci> (flip (<*>)) (print 1) (id <$ print 2) 2 1
Proposed improvements or changes
I would like to see a mention of the fact that the effects of the first argument are still performed before the effects of the second argument.
- GHC version used (if appropriate): 8.10.7
The source code contains this comment below the definition of
-- Don't use $ here, see the note at the top of the page
But I can't find that note (I looked at the top of the file and searched for
$, I assume the note should at least contain that character).