Re:Stackable Traits Pattern in Scala
by joefkelley on Monday February 15, 2016 @01:27PM
(#11105005)
This seems like more of an antipattern to me. If you have to be thinking about linearization order, your hierarchy is probably too complex.
[ Parent
| on HN ]
I have explained how linearization works, if you just wanna use it, its very easy. Just goes from right to left and you don't need to remember anything else. About anti pattern, I don't think so. It might not be useful every where, but at some places it makes sense to have stackable behavior.
I think the point is that if the hierarchy is complex enough that you have to think about it it's simple enough to figure. The cases presented are obviously over complex to describe the behavior.