>>> 5 & (+1) & show "6"
>>> sqrt $ [1 / n^2 | n <- [1..1000]] & sum & (*6) 3.1406380562059946
>>> 5 & (+1) & show "6"
>>> sqrt $ [1 / n^2 | n <- [1..1000]] & sum & (*6) 3.1406380562059946@since base-4.8.0.0
>>> :kind! Eval ('(True, Nothing) & Fst) Eval ('(True, Nothing) & Fst) :: Bool = True
>>> 5 & (+1) & show "6"
>>> sqrt $ [1 / n^2 | n <- [1..1000]] & sum & (*6) 3.1406380562059946
>>> (10,20) & _1 .~ 30 & _2 .~ 40 (30,40)
>>> (10,20) &~ do _1 .= 30; _2 .= 40 (30,40)This does not support type-changing assignment, e.g.
>>> (10,20) & _1 .~ "hello" ("hello",20)
>>> execState (do _1 &&= True; _2 &&= False; _3 &&= True; _4 &&= False) (True,True,False,False) (True,False,False,False)
(&&=) :: MonadState s m => Setter' s Bool -> Bool -> m () (&&=) :: MonadState s m => Iso' s Bool -> Bool -> m () (&&=) :: MonadState s m => Lens' s Bool -> Bool -> m () (&&=) :: MonadState s m => Traversal' s Bool -> Bool -> m ()
>>> both &&~ True $ (False, True) (False,True)
>>> both &&~ False $ (False, True) (False,False)
(&&~) :: Setter' s Bool -> Bool -> s -> s (&&~) :: Iso' s Bool -> Bool -> s -> s (&&~) :: Lens' s Bool -> Bool -> s -> s (&&~) :: Traversal' s Bool -> Bool -> s -> s