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

Delegates are not properly reformatted when converting property from expression body to block body #71637

Open
jhinder opened this issue Jan 14, 2024 · 0 comments
Labels
Area-IDE Bug help wanted The issue is "up for grabs" - add a comment if you are interested in working on it
Milestone

Comments

@jhinder
Copy link
Contributor

jhinder commented Jan 14, 2024

Version Used: VS 17.8.4

Steps to Reproduce:

For both properties, open the lightbulb menu and select "Use block body for property".

class C
{
    Action A => delegate
    {
    };

    Action A2 => () =>
    {
    };
}

Expected Behavior:
The block of the delegate or lambda is correctly indented.
image

Actual Behavior:
The indentation of the delegate body is not changed.

Interestingly, type creation expression within the property body are correctly formatted/indented:
image

@dotnet-issue-labeler dotnet-issue-labeler bot added Area-IDE untriaged Issues and PRs which have not yet been triaged by a lead labels Jan 14, 2024
@CyrusNajmabadi CyrusNajmabadi added Bug help wanted The issue is "up for grabs" - add a comment if you are interested in working on it and removed untriaged Issues and PRs which have not yet been triaged by a lead labels Jan 14, 2024
@CyrusNajmabadi CyrusNajmabadi added this to the Backlog milestone Jan 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-IDE Bug help wanted The issue is "up for grabs" - add a comment if you are interested in working on it
Projects
Status: InQueue
Development

No branches or pull requests

2 participants