Udostępnij przez


Błąd kompilatora C3237

"generic_class": klasa ogólna nie może być atrybutem niestandardowym

Uwagi

Klasy ogólne nie mogą być atrybutami zdefiniowanymi przez użytkownika.

Przykład

Poniższy przykład generuje kod C3237.

// C3237.cpp
// compile with: /clr /c
// C3237 expected
using namespace System;

generic <class T>
// Delete the following line to resolve.
[attribute(AttributeTargets::All, AllowMultiple=true)]
public ref class GR {};