Thu, 8 Feb 2001 12:46:29 +0100 (MET), Johannes Waldmann
<[EMAIL PROTECTED]> pisze:
> Yes, I see that. However I think that adding type signatures is
> good programming practice anyway, and I wouldn't mind if a future
> Haskell required me to do some explicit typing (for top-level
> definitions,
On 07-Feb-2001, Marcin 'Qrczak' Kowalczyk <[EMAIL PROTECTED]> wrote:
> So why is fmap separate now? Probably because having too much
> overloading causes ambiguities.
Perhaps. But I think there may be other reasons too.
Having fmap separate is useful for beginners and for teaching,
because you
> There is exponential growth of possibilities in compound expressions.
> And I'm afraid that ambiguities would happen in unexpected places and
> it would not be easy to find where to add type signatures. Especially
> as there is less explicit type information than in many other
> statically typed
Wed, 7 Feb 2001 10:08:14 +0100 (MET), Johannes Waldmann
<[EMAIL PROTECTED]> pisze:
> getLine:: IO String; getLine :: Handle -> IO String
>
> At each usage of getLine, the typechecker should follow both tracks,
> and take the one that is type-correct.
There is exponential growth of possibiliti
> import Handle as H
>
> H.getLine
>
> (This is a good example where type classes would not help
> making this any better, since the types of getLine and
> H.getLine are very different.)
not too different, I think; static overloading would help.
Just allow to have two (or more) identifiers