rudolflovrencic wrote:

> 
> > Fixes #183705 and #187993
> 
> Were those regressions?

We are no longer able to achieve this style in clang-format `v22`: 

```cpp
void f()
{
    return;
}

void g(int val)
{
    if (val > 42) { throw 42; }
    return;
}
```

In other words, from `v22` onwards, we cannot have:
- function definitions with a single statement **NOT** be formatted as a single 
line, **AND**
- braced `if` statements with a single statement be on a single line.

https://github.com/llvm/llvm-project/pull/196021
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to