3 ms·
> I'm curious if there are any practical reasons we don't see them implemented in more languages. I believe it's because they're not exactly easy to implement
by codethief 3y ago
> I'm curious if there are any practical reasons we don't see them implemented in more languages.
I believe it's because they're not exactly easy to implement and the resulting extensive type checking might also affect compiler performance.
By the way, another great example of refinement types (in JavaScript) is this one: https://kaleidawave.github.io/posts/introducing-ezno/ https://kaleidawave.github.io/posts/introducing-ezno/