[clang-format] Avoid adding space after the name of a function-like macro when the...
authorMarek Kurdej <marek.kurdej+llvm.org@gmail.com>
Thu, 3 Feb 2022 17:29:53 +0000 (18:29 +0100)
committerMarek Kurdej <marek.kurdej+llvm.org@gmail.com>
Thu, 3 Feb 2022 17:45:51 +0000 (18:45 +0100)
commit529aa4b011c4ae808d658022ef643c44dd9b2c9c
treeae429cfedfbcef9c9f9ddb390364b765df06538c
parent237eb37260e9091655e2c771155aab9a19cafad7
[clang-format] Avoid adding space after the name of a function-like macro when the name is a keyword.

Fixes https://github.com/llvm/llvm-project/issues/31086.

Before the code:
```
#define if(x)
```

was erroneously formatted to:
```
#define if (x)
```

Reviewed By: HazardyKnusperkeks, owenpan

Differential Revision: https://reviews.llvm.org/D118844
clang/lib/Format/UnwrappedLineParser.cpp
clang/unittests/Format/FormatTest.cpp