[PROPOSAL] !-notation from idris2

https://idris2.readthedocs.io/en/latest/tutorial/interfaces.html#notation

useful notation

instead of

foo = do
  x' <- bar
  case x' of
     Nothing -> ...
     Just x'' -> ...

one can write

foo = do
  case !bar of
     Nothing -> ...
     Just x'' -> ...
2 Likes

For reference: Monadic Bang: A plugin for more concise do-block notation, inspired by Idris - Announcements - Haskell Community

More tempting exclamations to make less readable notations.

I use this:

foo =
  bar >>= case _ of
     Nothing -> ...
     Just x'' -> ...
5 Likes

One can write

foo :: IO X
foo2 :: IO Y
bar :: X -> Y-> IO Z
main = log (show !(bar !foo !foo2))