diff options
author | rayroudc <rayroudc@gmail.com> | 2024-03-27 19:59:31 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-27 19:59:31 +0100 |
commit | dd06b8e679fd28f51cd065401062041a40b87f9c (patch) | |
tree | 1a56315777b0fc6c32eaefb3713b8694d7244419 /clang/lib/CodeGen/CodeGenModule.cpp | |
parent | e36ec2f40c7ea998dd11a485b01c32f50b7bf738 (diff) | |
download | llvm-dd06b8e679fd28f51cd065401062041a40b87f9c.zip llvm-dd06b8e679fd28f51cd065401062041a40b87f9c.tar.gz llvm-dd06b8e679fd28f51cd065401062041a40b87f9c.tar.bz2 |
[clang-format] Fix anonymous reference parameter with default value (#86254)
When enabling alignment of consecutive declarations and reference right
alignment, the needed space between `& ` and ` = ` is removed in the
following use case.
Problem (does not compile)
```
int a(const Test &= Test());
double b();
```
Expected:
```
int a(const Test & = Test());
double b();
```
Test command:
```
echo "int a(const Test& = Test()); double b();" | clang-format -style="{AlignConsecutiveDeclarations: true, ReferenceAlignment: Right}"
```
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
0 files changed, 0 insertions, 0 deletions