HomePhabricator

[CodeComplete] Consistently break after '{' in multi-line patterns

Authored by ilya-biryukov on May 28 2019, 7:33 AM.

Description

[CodeComplete] Consistently break after '{' in multi-line patterns

Summary:
Completion can return multi-line patterns in some cases, e.g.

for (<#init#>; <#cond#>; <#inc#>) {
<#body#>
}

However, most patterns break the line only before closing brace,
resulting in code like:

namespace <#name#> { <#decls#>
}

While some (e.g. the 'for' example above) are breaking lines after the
opening brace too.

This change ensures all patterns consistently break after the opening
brace, this leads to nicer UX when using those in an actual editor.

Reviewers: gribozavr

Reviewed By: gribozavr

Subscribers: cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D62405

llvm-svn: 361829