Space after comma with line break
I'd like to ask how to remove space after comma, when there is line break
so e.g in Enum
public enum Test
{
First = 1,
Second = 2,
}
After comma there is a white space on code cleanup. I would like to remove this kind of comma (everywhere there is a line break)
Please sign in to leave a comment.
Hello Marcin,
Could you please describe which space are you talking about? Is it a space after 1st comma, before the newline before 2nd element?
I mean there is always a space after comma on end of line. If there is multiple parameters chopped, collection initialization, etc. If line ends with comma, there is always single space after that comma. And I would like to avoid any spaces on the end of line. In any place.
Hi Marcin, Alex,
I'm also facing the same issue.
Were you able to resolve it yet?
Thanks
Looking for an answer to this. There is a StyleCop rule that insists on removal of spaces at end of lines, and I haven't found a way to get ReSharper to help conform, it always has to be cleaned up afterward.
There seems to be need for a setting "no space at end of line", which is either part of Spaces, or part of Line Breaks configuration.
Hello John Doggett
There's "Unnecessary whitespace at the end of line" inspection. Please enable it in ReSharper | Options | Code Inspection | Inspection Severity.
Thank you.