How to put summary/comment/help string to managed class/method?
From a managed DLL, I expose set of classes and public methods from it. Now I want to add help string for the class methods. In C# (Application or Class Libarary), this can be done by simply adding:
Code:
///<summary>
///Your help string here
///</summary>
public void foo(){}
But CLI (managed C++) compiler doesn't understand this. It never generates "summary" for the method! I looked up attributes (like ObsoleteAttribute), but not for adding help string.
Anyone knows?
Re: How to put summary/comment/help string to managed class/method?
That's strange...
Acording to this MSDN article, the delimeters for the xml documentation tags are the same as in C#.
Are you using the IDE, or the command-line clr compiler?
In any case, there's the /doc compiler option, and it also says here that
"XML documentation can be used regardless of whether you compile with or without /clr".
However, on the same page there's this:
Quote:
"Note:
In the current release, code comments are not processed on templates or anything containing a template type (for example, a function taking a parameter as a template). Doing so will result in undefined behavior."
And on the "/doc (Process Documentation Comments) (C/C++)" page, it also says something that might be relevant:
"/doc is not compatible with /clr:oldSyntax."