paul Hudak in his 'gentle introduction to haskell" says that a where clause
is allowed only at the top level of a set of equations or case expression.
So you cannot declare
let
f x = z / y where z = x + y
in
I do not know the reason why this restriction has
> There are two issues going on here.
>
> 1. Should pattern variables be permitted in the guard?
> ^^
> Haskell's reply: yes, but the result is always bottom.
Technically, it's only bottom if the pattern variables are evaluated.
This might seem
| paul Hudak in his 'gentle introduction to haskell" says that a where clause
| is allowed only at the top level of a set of equations or case expression.
|
| So you cannot declare
| let
| f x = z / y where z = x + y
| in
|
| I do not know the reason why this restri
There are two issues going on here.
1. Should pattern variables be permitted in the guard?
^^
Haskell's reply: yes, but the result is always bottom.
After all,
- you need to evaluate the guard to discover which
RHS to