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

    <tr>
        <th>Summary</th>
        <td>
            [clang-format] Mixed pointer and reference alignment suggestion
        </td>
    </tr>

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

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

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

<pre>
    By searching I found at minimum one issue (#136597) asking for a solution on this. It would really be cool to have an option for a mixed pointer and reference alignment for various cases (mainly return types, template arguments and anything else):

```c++
// Return type is aligned-left
// Argument is aligned-right
const char* my_function(const std::string& my_argument);

// Template argument is aligned-left
extern std::vector<const char*> list_of_strings;

// Variable is aligned-right
extern const char *my_cool_string;
```

We work on a large-scale project with this specific code style and mixed pointer/reference alignment is the only thing that practically stops us from auto-formatting the entire source tree :trollface:  

Thanks in advance!

</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJyMVM2O4jgQfhpzKYESBwIccqBnFmkOe1mNdo-twq4k3nZs5CrTw9uvnDBie9SHkSxxoL6_1GcjsxsCUad2L2r3dYVZxpi6HCRa4ry6RHvvXu7AhMmMLgzwDfqYgwUUmFxwU54gBgLHnAmUPijd1E27O-6VPgLyW8H0MQECR5_FxQAxgIyON_BN4D1mbyERen-HC4GJ0YNEGPFGgAHidYYsDJP7QRau0QWhBBgKsKdEwRCgd0OYKMg8e8PkYmYwyMTF1oQu-DskkpwCyP1KrPQXEJquHoUA05ALmmdaDHeZ05JnUvqompOq5tNWyzFKv5RTnZQ-K32Gv57M4HixQ3btqZfn0Omh8v-J5IaxjJgYWMCMmJQ-wXR_7XMwJbzSh-U_FluMNCeW5MKgdFvGfjqfbb48bC5y339N94kz-iGUwpP7RkZiUs2XD35U8wd4x_Ia-9dFnX8V-xuTw4unz7I9RJ6UoPRpur-WbT_4HnQ_v-9C_Q_Be0xvpTEIHtNAazboCa4p_ktG4N3JOJcJ-ErG9c6AiZaA5e5pXuWHzih9_qwxjkFGglgasuxdRhS4JjTizFxNlnhlyAx9ihNglrjuY5pQZBknoCAuEXDMyRBIIgLVnCRF73s0pJoTwJLq-4jhjcEFQHvDYEjpWlWnle0ae2yOuKKu3u_q5rCv2_1q7Kyp2mNjaXewuNtWTUv7o2nthfp-2_amXrlOV3pX7au6bnVb7Td7q21dH1tsmt5ic1HbiiZ0fuP9bdrENKzm-9rV23bXHlYeL-R5fgO0Nh7D8AintC6vQuoKbn3JA6ttVXrATyZx4uf34wNw9xX-_K3bynkYiEvPVzn5bhS5cmniXKrByZgvGxMnpc9F8fGzfuxf6fMchJU-P7LcOv1fAAAA___4OqAU">