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

Missing comma on last property causes wrapping due too comma insertion. #1354

Closed
SigtryggurO opened this issue Sep 25, 2024 · 0 comments · Fixed by #1370
Closed

Missing comma on last property causes wrapping due too comma insertion. #1354

SigtryggurO opened this issue Sep 25, 2024 · 0 comments · Fixed by #1370
Labels
area:formatting type:bug Something isn't working
Milestone

Comments

@SigtryggurO
Copy link

Input:

var new User()
{
    Name = user.name,
    Roles = [] // Todo set roles
};

Output:

var user = new User()
{
    Name = user.name,
    Roles =
    [] // Todo set roles
    ,
};

Expected behavior:

var new User()
{
    Name = user.name,
    Roles = [], // Todo set roles
};
@SigtryggurO SigtryggurO changed the title In object initalization if there is no comma behind the last property that has a comment the formatter wraps Missing comma on last property causes wrapping due too comma insertion. Sep 25, 2024
@belav belav added this to the 1.0.0 milestone Sep 25, 2024
@belav belav added type:bug Something isn't working area:formatting labels Sep 25, 2024
shocklateboy92 added a commit that referenced this issue Nov 4, 2024
…nt (#1370)

closes #1354

---------

Co-authored-by: Lasath Fernando <devel@lasath.org>
pisolofin pushed a commit to pisolofin/csharpier-editorconfig that referenced this issue Nov 16, 2024
…nt (belav#1370)

closes belav#1354

---------

Co-authored-by: Lasath Fernando <devel@lasath.org>
@belav belav modified the milestones: 1.0.0, 0.30.0 Nov 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:formatting type:bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants