
20 Oct
2013
20 Oct
'13
6:16 a.m.
Rein Henrichs wrote:
An action in this sense is just a function of type `Monad m => a -> m b' (or one where the monad is specified, like `a -> IO b'). This type signature fully specifies the "formal properties" of an action and shows that actions do not differ from functions: they are merely functions of a certain type.
I generally use the word "action" to refer to values of type `IO a` (or another monad). A value of type `a -> IO b` would be a function that returns an action. Best regards, Heinrich Apfelmus -- http://apfelmus.nfshost.com