How to use < > in Visual Studio comments?
-
16-09-2020 - |
Question
Below comment is just a piece of xml comment in VS but my problem is characters like < >
that break the xml structure. How can I use them in an xml comment?
/// <param name="index">square index on board which 1<=index<=64</param>
Solution
/// <param name="index">square index on board which 1<=index<=64</param>
OR
/// <param name="index">square index on board which 1〈=index〈=64</param>
The latter option is unicode: 〈 〉
OTHER TIPS
I would reword it to be more a sentence and less an equation:
/// <param name="index">square index on board, between 1 and 64</param>
Try encoding them? using < and >
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow