Skip to content

Comment on Does Scala as a FP Language Suffer From Its OO Syntax?parent

Comments

I think this point can not be stressed enough. Type classes have their place in day to day (Haskell) programming, but overuse quickly leads to bad abstractions that boil up from deep inside a codebase to all the way up to the public API.

My experience as a library author is that adding a type class for an additional layer of abstraction is easy and feels very natural. My experience as a library user is that understanding what problem the library author has solved using a type class can be very hard and confusing.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.