The new Haskell report 1.3 (preliminary) allows type variables of
other kinds than *, e.g. it gives the example (page 51)
data App f a = A (f a)
where the type variable f has kind *->*, and App has (*->*)->*->*.
My problem is that I haven't seen (in the report) any mention
about the in
Suggestion:
add another form of statement for monad expressions:
stmts -> ...
if exp
which is defined for MonadZero as follows:
do {if exp ; stmts} = if exp then do {stmts}
else zero
Based on this, one can define list comprehensions by
After browsing through the Standard Library Proposal for Haskell 1.3 (Version 3
>from September 6, 1995), I have the following questions:
1) The proposal for collections (sec. 4.2) mentions four different
_libraries_ which all define identical functions. IMHO, this should
better b
Lennart Augustsson wrote:
> It looks ugly, but we could say that a data declaration does not
> have to have any constructors:
>
> data Empty =
Philip Wadler responded:
> I'm not keen on the syntax you propose. How about if we allow the
> rhs of a data declaration to be just `empty', wh
Philip Wadler writes:
>
> > It looks ugly, but we could say that a data declaration does not
> > have to have any constructors:
> >
> >data Empty =
> >
> >-- Lennart
>
> I agree that the best way to fix this is to have a form of data
> declaration with no constructors, but
> It looks ugly, but we could say that a data declaration does not
> have to have any constructors:
>
> data Empty =
>
>-- Lennart
I agree that the best way to fix this is to have a form of data
declaration with no constructors, but I'm not keen on the syntax you
propose. How about
> Suggestion: Include among the basic types of Haskell a type `Empty'
> that contains no value except bottom.
Absolutely! But I don't think it should be built in
(unless absolutely necessary).
It looks ugly, but we could say that a data declaration does not
have to have any constructors:
> Suggestion: Include among the basic types of Haskell a type `Empty'
> that contains no value except bottom.
Absolutely! But I don't think it should be built in
(unless absolutely necessary).
It looks ugly, but we could say that a data declaration does not
have to have any constructors:
Thomas Hallgren <[EMAIL PROTECTED]> writes:
> In the syntax for labeled fields (records) the symbol <- is chosen
> as the operator used to associate a label with a value in
> constructions and patterns:
[...]
> According to a committee member, there were no convincing reasons
> why <- was chosen