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

Indenting with spaces after auto property code fix #29879

Open
ygoe opened this issue Sep 14, 2018 · 2 comments
Open

Indenting with spaces after auto property code fix #29879

ygoe opened this issue Sep 14, 2018 · 2 comments
Assignees
Labels
Area-IDE Bug help wanted The issue is "up for grabs" - add a comment if you are interested in working on it IDE-Formatter Code formatter and/or smart indent
Projects
Milestone

Comments

@ygoe
Copy link

ygoe commented Sep 14, 2018

Version Used:

Visual Studio 15.8.3 (.NET 4.6.2 WPF project in C# code)

Steps to Reproduce:

  1. Set up your environment to only ever use tabs for indenting, not spaces
  2. Write this code:
#region Private fields

private int field;

#endregion Private fields

#region Properties

public int Field
{
    get { return field; }
    set { field = value; }
}

#endregion Properties
  1. Use the suggested code fix to convert this into an automatic property.

Expected Behavior:

All indenting remains as tabs.

Actual Behavior:

Spaces. Not just the new property has spaces but also a few lines around it like #region/#endregion lines and the property that follows.

@CyrusNajmabadi
Copy link
Member

@heejaechang What is the right way to get the formatter to not use spaces in situations like this?

@heejaechang
Copy link
Contributor

sounds like a bug in formatter.

@heejaechang heejaechang self-assigned this Sep 14, 2018
@sharwell sharwell added Bug help wanted The issue is "up for grabs" - add a comment if you are interested in working on it labels Sep 18, 2018
@sharwell sharwell added this to InQueue in Small Fixes via automation Sep 18, 2018
@sharwell sharwell added this to the Unknown milestone Sep 18, 2018
@ryzngard ryzngard removed the help wanted The issue is "up for grabs" - add a comment if you are interested in working on it label Oct 30, 2018
@ryzngard ryzngard assigned ryzngard and heejaechang and unassigned ryzngard and heejaechang Oct 30, 2018
@ryzngard ryzngard added the help wanted The issue is "up for grabs" - add a comment if you are interested in working on it label Oct 30, 2018
@CyrusNajmabadi CyrusNajmabadi added the IDE-Formatter Code formatter and/or smart indent label Feb 10, 2023
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 IDE-Formatter Code formatter and/or smart indent
Projects
Small Fixes
  
InQueue
Development

No branches or pull requests

6 participants