Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposal: do not require <description> in <list> without <term> #1765

Open
sharwell opened this issue Aug 2, 2018 · 0 comments
Open

Proposal: do not require <description> in <list> without <term> #1765

sharwell opened this issue Aug 2, 2018 · 0 comments
Assignees
Labels
Milestone

Comments

@sharwell
Copy link
Member

sharwell commented Aug 2, 2018

Motivation

Currently, the C# language specification describes the <item> documentation element as always requiring the child element <description>. This includes cases like numbered and bulleted lists where the <term> element is omitted. In these cases, the <description> element is unnecessarily verbose and the compiler does not provide an assistance in creating conforming documentation comments.

dotnet/machinelearning#529 (comment)
dotnet/roslyn#29018

Detailed design

The C# language specification is updated as follows (final wording TBD):

If an <item> element within a <list> element is missing both the <term> and <description> elements, the inner XML of the <item> element is treated as the inner XML of an implicit <description> element.

In other words, the following become equivalent:

<list type="number">
  <item><description>Text of the item</description></item>
</list>

<list type="number">
  <item>Text of the item</item>
</list>

Remarks

This behavior aligns with both user expectations and the long-standing behavior of Sandcastle Help File Builder. This behavior also aligns with the current C# compiler behavior and the IDE experience, so implementation of the proposal will be limited to a change in the wording of the language specification to allow this case.

/cc @EWSoftware @BillWagner @sfilipi

@sharwell sharwell changed the title Proposal: do not require description in lists without terms Proposal: do not require <description> in <list> without <term> Aug 2, 2018
sharwell added a commit to sharwell/DocumentationAnalyzers that referenced this issue Sep 15, 2018
@DustinCampbell DustinCampbell self-assigned this Sep 17, 2018
@MadsTorgersen MadsTorgersen added this to the X.0 candidate milestone Sep 19, 2018
@MadsTorgersen MadsTorgersen added the Blocked Waiting for a dependency label Sep 19, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants