dotnet/roslyn

<inheritdoc cref> has bad default for `path` attribute, leading to senseless inherited doc

Aperta

#45.994 aperta il 15 lug 2020

 (2 commenti) (0 reazioni) (0 assegnatari)C# (4257 fork)batch import
Area-IDEConcept-Continuous ImprovementIDE-IntelliSensehelp wanted

Metriche repository

Star
 (20.414 stelle)
Metriche merge PR
 (Merge medio 6g 17h) (256 PR mergiate in 30 g)

Descrizione

Version Used: 16.8 (30313.166.master)

Steps to Reproduce:

public class C
{
    /// <param name="a"><inheritdoc cref="M(int,int)" path="/param[@name='a']"/></param>
    public void M(int a)
    {
        if (a > 0)
        {
        }
    }

    /// <summary>summary</summary>
    /// <param name="a">A description</param>
    /// <param name="b">B description</param>
    public void M(int a, int b)
    {
        if (a > 0 || b > 0)
        {
        }
    }
}

Expected Behavior:

I expect the default path to provide the same meaning as the explicitly specified path, as shown here:

image

Actual Behavior:

Instead, I see a concatenation of all param docs together, with not so much as a delimiter:

image

Guida contributor