|
|
|
|
|
by a0
2778 days ago
|
|
In principle it seems like a significant limitation but in practice it is rarely an issue. ReasonML does support parametric polymorphism so it is still possible to write generic code. Some language features conveniently help to avoid boilerplate. For example it’s possible to have a `Float` module with arithmetic operators and “open” it like this: `Float.(10.0 + 0.5 / 3.0)`. There’s also a work in progress project called Modular Implicits that will introduce ad-hoc polymorphism. |
|