Dela via


Kompilatorfel CS0306

Typen "typ" kanske inte används som ett typargument

Den typ som används som en typparameter tillåts inte. Det kan bero på att typen är en pekartyp.

I följande exempel genereras CS0306:

// CS0306.cs  
class C<T>  
{  
}  
  
class M  
{  
    // CS0306 – int* not allowed as a type parameter  
     C<int*> f;  
}