[clang-format] Special handling of spaces for C# code
authorJonathan Coe <jbcoe@google.com>
Wed, 26 Feb 2020 15:13:09 +0000 (15:13 +0000)
committerJonathan Coe <jbcoe@google.com>
Wed, 26 Feb 2020 15:27:03 +0000 (15:27 +0000)
commite8c5fea243ce30640ec9707fabdb635a49b3153c
treeaaf0a24d3d2b0451ec66dfd0944a1ee87e147e41
parent02323a3d5f9ea676865f78d603e68fa4b4b62608
[clang-format] Special handling of spaces for C# code

Summary:
Ensure that there are spaces around braces '{', '}'.

Ensure that there is a space before and after '=>'.

Ensure that 'async' and 'when' are considered as keywords when inserting spaces.

Reviewers: krasimir, MyDeveloperDay

Reviewed By: krasimir

Tags: #clang-format

Differential Revision: https://reviews.llvm.org/D75129
clang/lib/Format/FormatToken.h
clang/lib/Format/TokenAnnotator.cpp
clang/unittests/Format/FormatTestCSharp.cpp