<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/58204>58204</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            clang-format with C++20 likely/unlikely attributes breaks indentation
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          gohar94
      </td>
    </tr>
</table>

<pre>
    When I run `clang-format` on the following code, it gives me weird indentation where it encounters `likely/unlikely`.

Input [`foo.cpp`]:
```c++
#include <iostream>

int foo(int a) {
  if (a == 0) [[likely]] {
    return 1;
  }

  if (a%2 == 0) {
    std::cout << "Even" << std::endl;
    return 1;
  }

  return 2;
}
```

Output:
```c++
#include <iostream>

int foo(int a) {
  if (a == 0) [[likely]] {
      return 1;
    }

  if (a % 2 == 0) {
    std::cout << "Even" << std::endl;
    return 1;
  }

  return 2;
}
```

Expected Output:
```c++
#include <iostream>

int foo(int a) {
  if (a == 0) [[likely]] {
    return 1;
  }

  if (a % 2 == 0) {
    std::cout << "Even" << std::endl;
    return 1;
  }

  return 2;
}
```

Command:
```
clang-format foo.cpp --fallback-style=Google
```

Notice how the `if` block with `likely` appears different than the second one (without any attributes).

Are there any particular options that can be passed to `clang-format`  (or in a `.clang-format` file) to achieve the expected output?
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJzVVU1z2yAQ_TXosmOPhCzbOuiQ2HEnl_bYMxIriRqDBlDc_PsuspMoTTLT3pIZRgL2-y08aisfq589GrgHNxpg67TRwnSL1rqTCLQEayD0CK3V2p6V6aCxEhnfgQrQqQf0cEI4o3ISlJFoggiKbM49Oow6aBo7moDOR-9aHVE_Mn4YzXW6Tpcs3bP05vK9N8MYgBW3JGitXTbDQDNW7Fl-1YjLaTSM38Zx2eW5Mo0eJQLLd8r64FCcWH43d65MoEIs49s4E4yXwDZXBwCqBZIIsqdge0gnMSVS3F5TpSSK_dwCwGEYnYGM5c-bbLOfx3z2y3jBX_ueO_JBxgrzG0IrxBJokBm_e0BDv6edZzU0Us-C_lsmVx3-rPOi8QTq3ODHGKgZnxP4dwv-GHz6FPDF4L_7PWATUMJn7sN_XICv2IOdPZ2EkW-xvyznZAlXuoLFohVa16I5Lnx41EjVfrO2o8nHcb7boBqE3p4ntiWpaiP71to2Rzir0M_Yk_bFMKAgSpWqbYloqZmhFxem9thYI4m3MaIeTSOcwjyCCMGpegzoCftXrHtDXB0mxo56g3CUzaiFAztENvfRe4CGItRIYu_pVAb73nMRY1pHTwGIKF7-LW8V4UCdJ2vR9AofpsCAT2fdXs_6IcEqW6-LdJsXZZ7IKpdlXookqKCxeoX7hM7uchd4Cm-emFndUNOlOPr5S5WMTld9CIOPTeYHGh05HOtlY0-00Prh6bcYnP1FadJSeT9GGA_FlqerpK_WeV3XWG7XpawReSGLFeebLOPbzabdYJNoUaP2VbxPnBs8w-SC5nSlElXxlPMsTddZmeVZvhTFqpR5mm25lKXIGrZK8SSUXsY8ltZ1iaumlOqx8yTUygf_IqQOqc4gTuHIvxjpFLiqs71w5SqZQldT6n8Awxk4Mg">