@@ -495,8 +495,8 @@ values:
495495 Env = List (String, Integer)
496496
497497 eval : Expr -> Eff Integer [EXCEPTION String, STATE Env]
498− eval (Val x) = return x
499− eval (Add l r) = return $ !(eval l) + !(eval r)
498+ eval (Val x) = pure x
499+ eval (Add l r) = pure $ !(eval l) + !(eval r)
500500
501501Note that we are using ``!``-notation to avoid having to bind
502502subexpressions in a ``do`` block. Next, we add a case for evaluating
@@ -506,7 +506,7 @@ subexpressions in a ``do`` block. Next, we add a case for evaluating
506506
507507 eval (Var x) = case lookup x !get of
508508 Nothing => raise $ "No such variable " ++ x
509− Just val => return val
509+ Just val => pure val
510510
511511This retrieves the state (with ``get``, supported by the ``STATE Env``
512512effect) and raises an exception if the variable is not in the
@@ -559,7 +559,7 @@ has been generated:
559559
560560 eval (Random upper) = do val <- rndInt 0 upper
561561 putStrLn (show val)
562− return val
562+ pure val
563563
564564If we try this without extending the effects list, we would see an
565565error something like the following: