Compiler Warning (level 3) C4580
TOC
Collapse the table of content
Expand the table of content
Important This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here. ArchiveDisclaimer

Compiler Warning (level 3) C4580

Error Message

[attribute] is deprecated; instead specify System::Attribute as a base class

attribute is no longer the preferred syntax for creating user-defined attributes. For more information, see User-Defined Attributes.

Example

The following sample generates C3454.

// C4580.cpp
// compile with: /W3 /c /clr
[attribute]   // C4580
public ref class Attr {
public:
   int m_t;
};

public ref class Attr2 : System::Attribute {
public:
   int m_t;
};
Show:
© 2016 Microsoft