Q:

Scala generics in comparison to C#

I'm just wondering about an implementation detail of Scala generics.  In C# one can declare a class as:
class Foo<T1>{}
class Foo<T1, T2>{}

In Scala however the same thing would have to be declared as
class Foo0[T1]{}
class Foo1[T1, T2]{}

Notice how the class name is forced to be changed for multiple generic parameters.   Is there a reason that Scala decided to go this route rather than the C# one which I feel is more elegant?   I know this is probably a pretty small nitpick, but I'm pretty curious as to the reasoning. 

A:

I know Jon Skeet's answer has been accepted, but it's not quite right.   It's not so much the JVM that forces a limitation as it is the Java language.   Scala has a design goal of being as easily callable from Java as possible and Java has no concept of overloading a class name based on type parameter arity.   For instance, a simple way to implement overloading based on type parameters on the JVM would be with name mangling.   However that name mangling would have to be visible to Java and would be ugly.   In your example, a hypothetical Scala might compile two classes, Foo_$1 and Foo_$2.   Scala could make that mangling invisible.   However, a Java programmer would see all that ugliness. 

A:

It may well be partly due to Java's similar restrictions.  As I understand it, Scala is mostly used on the JVM, where you can't overload generic types by arity. 
It looks like Scala uses type erasure for its generics too, even in the .NET port. ( The same article mentions that Scala had generics long before Java really did, so even if Java did support this, there's no guarantee that Scala would - they were somewhat restricted when they first designed the feature.)