Attribute to mark code

Posted by happyclicker on Stack Overflow See other posts from Stack Overflow or by happyclicker
Published on 2010-06-13T13:58:52Z Indexed on 2010/06/13 14:02 UTC
Read the original article Hit count: 363

Filed under:
|
|

In c# there are attributes such as [obsolete] that create compiler warnings that will be shown in visual studio.

Is there an attribute that I can use to mark a method or a class with a comment that should be shown as a warning in visual studio when I compile?

Something like:

[TBD(Msg="Please change me after 2010 07 20")]
public void Foo(){
}

or is there a possibility that I can derive from System.Attribute and make my own attribute, configuring visual studio so that it behaves as I described.

© Stack Overflow or respective owner

Related posts about c#

Related posts about .NET