Repository: TypeScript
Issue: Incorrect Formatting For Class With Decorator 
Labels: Bug,Help Wanted,Domain: Formatter,VS Code Tracked

<!-- BUGS: Please use this template. -->
<!-- QUESTIONS: This is not a general support forum! Ask Qs at http://stackoverflow.com/questions/tagged/typescript -->
<!-- SUGGESTIONS: See https://github.com/Microsoft/TypeScript-wiki/blob/master/Writing-Good-Design-Proposals.md -->

From https://github.com/Microsoft/vscode/issues/21723

**TypeScript Version:**  2.2.1

**Code**

```ts
function Component(x) {
  return x
}

@Component
export class Foo {bar(): void {
return 2
}

}
```

Set formatting options to two spaces and run document format

**Expected behavior:**
Class is formatted with two spaces as

```ts
@Component
export class Foo {
  bar(): void {
    return 2
  }

}
```


**Actual behavior:**
Class is formatted with four spaces:

```ts
@Component
export class Foo {
    bar(): void {
      return 2
    }

} 
```

Running format again returns to the correct two space formatting

```
[Trace - 5:55:14 PM] Sending request: configure (12). Response expected: yes. Current queue length: 0
Arguments: {
    "file": "/Users/matb/projects/sand/x.ts",
    "formatOptions": {
        "tabSize": 2,
        "indentSize": 2,
        "convertTabsToSpaces": true,
        "newLineCharacter": "\n",
        "insertSpaceAfterCommaDelimiter": true,
        "insertSpaceAfterSemicolonInForStatements": true,
        "insertSpaceBeforeAndAfterBinaryOperators": true,
        "insertSpaceAfterKeywordsInControlFlowStatements": true,
        "insertSpaceAfterFunctionKeywordForAnonymousFunctions": true,
        "insertSpaceBeforeFunctionParenthesis": false,
        "insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis": true,
        "insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets": false,
        "insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces": false,
        "insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces": false,
        "placeOpenBraceOnNewLineForFunctions": false,
        "placeOpenBraceOnNewLineForControlBlocks": false
    }
}
[Trace - 5:55:14 PM] Response received: configure (12). Request took 4 ms. Success: true 
[Trace - 5:55:14 PM] Sending request: format (13). Response expected: yes. Current queue length: 0
Arguments: {
    "file": "/Users/matb/projects/sand/x.ts",
    "line": 1,
    "offset": 1,
    "endLine": 10,
    "endOffset": 2
}
[Trace - 5:55:14 PM] Response received: format (13). Request took 36 ms. Success: true 
Result: [
    {
        "start": {
            "line": 1,
            "offset": 20
        },
        "end": {
            "line": 1,
            "offset": 20
        },
        "newText": " "
    },
    {
        "start": {
            "line": 1,
            "offset": 21
        },
        "end": {
            "line": 1,
            "offset": 21
        },
        "newText": " "
    },
    {
        "start": {
            "line": 6,
            "offset": 19
        },
        "end": {
            "line": 6,
            "offset": 19
        },
        "newText": "\n"
    },
    {
        "start": {
            "line": 6,
            "offset": 19
        },
        "end": {
            "line": 6,
            "offset": 19
        },
        "newText": "    "
    },
    {
        "start": {
            "line": 7,
            "offset": 1
        },
        "end": {
            "line": 7,
            "offset": 1
        },
        "newText": "      "
    },
    {
        "start": {
            "line": 8,
            "offset": 1
        },
        "end": {
            "line": 8,
            "offset": 1
        },
        "newText": "    "
    }
]