2 ms·
I suspect type inference becomes pretty tricky in the presence of subtyping. I don't have any F# experience, but I have done some Haskell back in the days and
by Thiez 5y ago
I suspect type inference becomes pretty tricky in the presence of subtyping.
I don't have any F# experience, but I have done some Haskell back in the days and I found the type inference very convenient. But I also think there is something to be said for limiting type inference to "inside" methods where it is effectively invisible to users of a class. Rust has made the same choice: you have type inference inside functions, but never outside.