Like this, you mean? https://haskellforall.com/2012/05/scrap-your-type-classes

Fine in principle, but AFAIK it never really caught on because the ergonomics suck. Interfaces/traits/type classes do seem to be a popular feature across languages, for what it's worth.