I want to implement method chaining like in those questions:
Best practice to implement Scala trait which supports method chaining ;
Scala DSL: method chaini
here you can ifnd an improved solution :
http://jim-mcbeath.blogspot.fr/2009/09/type-safe-builder-in-scala-part-3.html
(which actually relies on the phantom types)