2 ms·
In some dependently typed languages they can be easily implemented via refinement types, where the “refinements” are the implementations of the typeclass requir
by johncolanduoni 8y ago
In some dependently typed languages they can be easily implemented via refinement types, where the “refinements” are the implementations of the typeclass requirements. Idris is a good example of this approach.
It has the advantage of making typeclasses first-class, and of enabling a lot of additional functionality without additional fundamental constructs. It is however very antithetical to what someone means when they say Go is minimalistic.