Wishful thinking

time to read 1 min | 146 words

I wish we could do the following:

// CS0689.cs

class A<T> : T   // CS0689

{
}

That is, inherit from a type paraemeter. Unfortunately, this is forbidden by the C# compiler (CS0689 error, as you can see). The options that this would've opened are quite impressive. This is one technique that you can use in C++, and it's very impressive one. Anyone can pipe in with the reason for this limitation? And whatever it's a C# or CLR one?