Hello Fawzi, Tuesday, March 20, 2007, 5:37:45 PM, you wrote:
> ambiguous function call at line xxx. > Possible instances are: > f: Int -> String -> Double -> a > f: String -> Int -> [Int] -> a > please explicitly annotate the type to disambiguate > Note that you want to use also the type of the result to disambiguate. > Not easy, but doable, and done, again I can understand why haskell did > not do it. you not yet realize the whole problem :) in traditional languages, all type information flows in one direction and when compiler see f(x,y,z) call, it already knows x/y/z types because they should be declared earlier. but in haskell types of these variable may be defined by subsequent calls. so imagine several such overloaded calls - "f x y z", then "g (h x) (h y)", and more and more. error messages will become so complicated that you will shoot the compiler :) -- Best regards, Bulat mailto:[EMAIL PROTECTED] _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe