Lists as function parameters

Topics: Developer Forum, User Forum
Sep 23, 2009 at 2:59 PM

I'm using VS C++ 2005 together with SHFB 1.8.0.2 and I can't seem to generate help for methods taking two or more Lists as parameters.

Created a small test project with a simple function:

///<summary>List as parameter test function.</summary>
  ///<param name="firstList">First test list.</param>
  ///<param name="secondList">Second test list.</param>
  ///<remarks>Remarks appearing here...</remarks>
  ///<returns>Return zero.</returns>
  int ListTestFunc(List<String^>^ firstList,List<String^>^ secondList){
     return 0;
  }

 This all gets carried over to the generated XML file,

<member name="M:testlist.Form1.ListTestFunc(System.Collections.Generic.List`1{System.String^},System.Collections.Generic.List`1{System.String^})">
  <summary>List as parameter test function.</summary>
  <param name="firstList">First test list.</param>
  <param name="secondList">Second test list.</param>
  <remarks>Remarks appearing here...</remarks>
  <returns>Return zero.</returns>
</member>

but when I build the help file I get complaints of missing <summary>, <returns> and <param> tags (all params). None of the XML tags are entered into the final document.

If I comment out the second List parameter and its <param> tag, no problems, but having that second List parameter seems to break the generation in some way.

Coordinator
Sep 23, 2009 at 4:03 PM

Have you tried setting the CppCommentsFixup property to true?  The C++ compiler doesn't always output the correct method signatures to the XML comments file.  The project property will fix most of them if set to true.  If it doesn't work, it's possible you've found another case where they don't match what Sandcastle expects.

Eric

 

Sep 24, 2009 at 10:15 AM

CppCommentsFixup did not fix the problem unfortunately.