[Haskell-cafe] do we have something like isDefined or isNull
in Haskell?
Clifford Beshers
clifford.beshers at linspire.com
Thu Jun 15 15:07:33 EDT 2006
Duncan Coutts wrote:
> On Thu, 2006-06-15 at 13:11 +0100, Duncan Coutts wrote:
>
>
>> then you can construct your records using:
>>
>> foo = default { weight = 3.2 }
>>
>
> Oops, as David House pointed out to me that should of course be
>
> foo = default { weight = Just 3.2 }
>
I think the correct response in these cases is: That was left as an
exercise for the type checker.
On another note, who picked the word `Just' for this type and how did we
end up with Some x | None in O'Caml and Just x | Nothing in Haskell?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org//pipermail/haskell-cafe/attachments/20060615/3dee7142/attachment.htm
More information about the Haskell-Cafe
mailing list