Generating Type Class Instances Automatically

Generating Type Class Instances Automatically

The use of type classes has become pervasive in Scala programming. There are several libraries facilitating them to let developers write highly generic code. Because of the encoding of type classes in Scala, we have the whole power of the language (and now even macros) to derive instances of type classes. With proper library support, it is possible to compose small building blocks into type class instances for your own data types with (almost) no boilerplate.

A1216674d5c9747bcdcc716872439137?s=128

Lars Hupel

July 02, 2013
Tweet