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

SA1512 (A single line comment must not be followed by a blank line) should allow blank line between single line comments and documentation comments #1130

Closed
oatkins opened this issue Aug 6, 2015 · 4 comments · Fixed by #1149
Assignees
Milestone

Comments

@oatkins
Copy link
Contributor

oatkins commented Aug 6, 2015

The following generates a warning for the SA1512 analyzer, but not in legacy StyleCop:

// Some comments.

/// <summary>Some summary.</summary>
public void A()
{
}

Removing the space eliminates the warning. However, without the space, legacy StyleCop would report SA1514. (See issue #1131.)

These issues might seem unimportant, but I doubt that I am alone in having many classes that have code comments followed by documentation comments, following the SC rules.

@Noryoko
Copy link
Contributor

Noryoko commented Aug 7, 2015

Grabbing this.

Noryoko added a commit to Noryoko/StyleCopAnalyzers that referenced this issue Aug 7, 2015
Noryoko added a commit to Noryoko/StyleCopAnalyzers that referenced this issue Aug 7, 2015
Noryoko added a commit to Noryoko/StyleCopAnalyzers that referenced this issue Aug 7, 2015
Noryoko added a commit to Noryoko/StyleCopAnalyzers that referenced this issue Aug 7, 2015
@RalfKoban
Copy link
Contributor

Hi,

using Beta 6, I'm experiencing a similar issue (SA1514) for following code snippet:

    public override bool SomeMethod() => true; // some comment

    /// <summary>
    /// ...
    /// </summary>
    public override void SomeOtherMethod()
    {
    }

Best regards,
Ralf

@sharwell
Copy link
Member

@RalfKoban Can you open a new issue for that?

Thanks! 👍

@sharwell sharwell added the fixed label Aug 15, 2015
@RalfKoban
Copy link
Contributor

@sharwell
Of course. Reported as issue #1215.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants