10 Pines Blog

Mixins or Traits? That is the Question

trait mixin java inheritance behavior interfaces

A couple of days ago, a discussion came up in an uqbar foundation[^1] mailing list about the Java 8 Interfaces Default Methods. They were named as «mixins», but I corrected them and called «traits without flattening».

After sending the mail, that last sentence kept ringing in my head, so I proposed myself to try to understand why was I calling them like that. But first things first.

14 Oct 2014