That is because they are generic most of the time.
This is also fun when using `#trace`in the REPL and all you see is `<poly>` instead of the "real" value
That is because they are generic most of the time.
This is also fun when using `#trace`in the REPL and all you see is `<poly>` instead of the "real" value
* intent of the author not clear
* auto-complete etc. doesn't work as well
* type errors not caught as early (for generics this means you get super confusing type errors)
Obviously some functions are intended to be generic (e.g. operations on containers) but typical OCaml code seems to contain functions that are actually only called with one type - and the author only intended for them to be called with one type - yet they get inferred as generic.
Oh yes, I'm not arguing against that or your other points. I just wanted to express that the types being inferred as generic is not an error, but by design.