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

    <tr>
        <th>Summary</th>
        <td>
            [clang-format] Awkward requires formatting with RequiresClausePosition: OwnLine
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            clang-format
      </td>
    </tr>

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

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

<pre>
    I think this counts as a defect report, rather than a feature request. With `RequiresClausePosition: OwnLine`, a function's open paren is placed at the beginning of a line, which is inconsistent with the underlying style of putting at the end of the preceding line.

Here's a formatting with that option. As you can see, in a declaration, the ending semicolon occupies the same line as the requires clause, but in a function definition, the opening brace does not.
```
// BasedOnStyle: LLVM
// RequiresClausePosition: OwnLine
// AlwaysBreakTemplateDeclarations: Yes

template <typename T>
int frob()
  requires(true); // semicolon at EOL, expected

template <typename T>
int Frob(T)
 requires(true)
{ // brace at SOL, unexpected
  return 00000000000000000000000000000000000000000;
}

template <typename T>
  requires(true)
class X; // class at SOL, expected
```
IMHO that definition would be better formatted as:
```
template <typename T>
int Frob(T)
  requires(true) {
  return 00000000000000000000000000000000000000000;
}
```

</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJysVU2P4jgQ_TXmUmqUOJDAIQc-Bs1IPerVTms_jhWnIN42dsYuD8u_XzmBoRm1NNurRSiAy_Xeq1cugyHogyWqxXwt5tsJRu6cr6O3yB3aSePac_0JuNP2JT0DKBctB8AACC3tSTF46p1nITfgkTvykFIBYU_I0RN4-hop8BR-19yBKLNf6WvUnsLGYAz0iwuatbOiWMHTyT5qS6LMEhzCPlo1xGQVwPVkoUdPFnSA3qCiFpCBO4KGDtpabQ_g9oBgEojcwKnTqku7tVXOBh2YLMMp6UhZ0bbkzTmlBT4bSsl9ZE4LF2CybVpNX3tPitoUS_BTkW1FthqfH8nToBFh7_wRR4gLDzK4PlUxhVWAs4ug0EKgQaG2g5HKoMex0s2Vd5BFR62ccRacUrHXFIZowCMNKlIj0oK_WApq8DShNJFH9KuJqV_a6tcsydJE03hUBK2jANbxtbQyu7zHn3In5A7WGKh9sl-SX6llj4-_fb7b8PPuvt69Mic8h7UnfHmmY2-QaXtzI6S0Pym89pov20AUGz73ZJMXz6L4MIa1Zdh71wi5EHI5rsF3f4RcsI-UIsUaLhpuJiPDh6fH5A793ZNiat_JvBuZn2_UbzCPkNV3_tF9ZPgyckd7z57kc_QWsn_7EsX6yrJ9RwVv-jRElMEQ4I9Xpo0rN9E_GHZ_dj59_vg0TsLtDMLJRdNCk4aXmfx1ctJQp76_CfSfWvBGVSCq9f9o7r3ISVsX7bJY4oTqvJJyPsuzcj7p6qItULWzpsnlcqEWuMwxL6tSKapyoiKf6FpmcpYtsjxfFtWsmOZFm5VNWVVVuSzkfCZmGR1Rm6kx345T5w8THUKkOs_y-TybGGzIhOE2l1IZtIeH0VUhZbrffZ3yHpp4CGKWGR043JBYsxn-Ce4S51tYnV5O6NvbJfPjHffTkZ9Eb-qOuR8aOxygg-YuNlPljkLukobLx0Pv3V-kWMjdUFoQcnep7lst_wkAAP__KXMVZA">