3 ms·
I wonder if there's any hope of ever getting type classes in OCaml. Then you'd be able to have stuff like a single "print" function you can give any type of val
by rsaarelm 16y ago
I wonder if there's any hope of ever getting type classes in OCaml. Then you'd be able to have stuff like a single "print" function you can give any type of value that can be turned into a string representation.
- Yoric 16y agoAfaik (and according to Xavier Leroy), it's not planned in mainstream. Now, implementation of typeclasses is pretty-well documented, so if anyone's willing to finance OCamlPro on this, I don't think there's any technological or scientific barrier.
- pdhborges 16y agoType classes or module implicits, that would be great.