dotnet / dotnet/vscode-csharp

Missing auto indenting inside of switch blocks

Open
#156 6 comments 0 reactions 0 assignees View on GitHub
Bug Editor-Formatting
Dominant language
TypeScript
Stars
3.1k
Forks
737
Avg merge
18h 40m
Merged PRs (30d)
31

Description

VSCode Version: 0.10.11
OS Version: OSX, Win10

Scenario 1:
Create a switch statement:
![image](https://cloud.githubusercontent.com/assets/10537189/14334094/ecca3e98-fc06-11e5-8d83-4a4920166e64.png)
Create a new line above default:
Inside that line type case 0:
Hit enter

Expected (normal VS product behavior): The editor should auto indent after hitting enter
Actual: No indent occurs. See below
![image](https://cloud.githubusercontent.com/assets/10537189/14334186/824a9bc0-fc07-11e5-8064-ba9dad574827.png)

Scenario 2:
Create a switch statement. Use the same as how scenario 1 started.
Move the cursor to after the 'break;' Hit enter.
Cursor will be at the same Ch spot as the b in break.
Type case 0:

Expected (normal VS product behavior): The editor should auto un-indent case 0: after typing the colon
Actual: No indent occurs. Looks like the following:
![image](https://cloud.githubusercontent.com/assets/10537189/14334274/1c45d8ac-fc08-11e5-9836-3b216499c7d9.png)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.