Understanding Type Classes, Scala implicit and C# -
i read blog post joe duffy haskell type classes , c# interfaces. i'm trying understand have enabled c# have type classes, , wonder whether feature scala's implicits solve it? having kind of feature enable writing this: public interface ireducableof<t> { t append(t a, t b); t empty(); } public t reduce(this ienumerable<t> vals, **implicit** ireducerof<t> reducer ) { enumerable.aggregate(vals, reducer.append); } making sure have in our context implementation of ireducerof<t> compiler "just" pick reducer , use execute code. of course, code cannot compile. but questions are: can enable implementing type classes? is similar happening in scala? i'm asking general understanding , not particular problem. update i've encountered github repo on possible implementation of type classes in c# yes, how type classes implemented in scala. general design principle in scala add general , re-usable features