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

    <tr>
        <th>Summary</th>
        <td>
            [clang-format] JavaScript prototype functions become more and more indented
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            clang-format,
            new issue
      </td>
    </tr>

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

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

<pre>
    If I have a JavaScript file `Test.js` like this:

```
function Test() {
    this.test = true;
}

Test.prototype.myFunc1 = function (fuu) {
    return fuu;
}

Test.prototype.myFunc2 = function (fuu) {
    return fuu;
}

Test.prototype.myFunc3 = function (fuu) {
    return fuu;
}

Test.prototype.myFunc4 = function (fuu) {
    return fuu;
}
```

and I format it with clang-format and a config file (It doesn't matter which style I use):
```
BasedOnStyle: Chromium
```

I get a result of this:
```
function Test() {
  this.test = true;
}

Test.prototype.myFunc1 =
 function(fuu) {
  return fuu;
}

    Test.prototype.myFunc2 =
 function(fuu) {
  return fuu;
}

 Test.prototype.myFunc3 =
            function(fuu) {
  return fuu;
}

            Test.prototype.myFunc4 = function(fuu) {
 return fuu;
}
```

I would have expected that the is no indentation before the prototype function definitions like in the first place.

Tested with clang-format version 16.0.6. and 17.0.0-rc4
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJy0Vd1u4yoQfhp8M4qFcWzHF75oG0VKdaRz0fMCxB7H9GCIYEg2b78ySZr-7m61LYoIZuD7BuYbRnqvtgaxYcUtK5aJDDRY19zbQRqD_h8Z-h5dsrHdsVn3sIZB7hEk3Mu9fGid2hH0SiOwkv-HntJHz0oOWv2PQIPyLL9hfMn4pS_5-Rc_-2BaUtbAtJWJBRM1sOr2ZASACJESegKWL4FcQJafzaxaPkeO5DtnydJxh-l4XAXTZnHbEwsTiz6ENyQOKTgDk-kz4OI7wfPvBJ__PfjLOJ56aTpYQ2_dKAkUwUHRAK2WZjs7T04rJLTW9Gp7lo1YrAk6i94wURGMkggdHAbVDuDpqBHWEDwyUV-l9JL8Vnrs_jUP02KW38Dd4OyowvgLT9ewRQIJDn3QBLZ_pdVPqfQrNHrGujC9G5HfB3uK2sdS_SKOj-V6deLSvuA8l_YHQn6P5dMiXsPBBt2dnjn8scOWsAMaJAENCMqDsaBMh4ZkFMUGe-swGp_cu-ZWh70yahr606OoTFzaK-cJdlq2mL6WCHbvpM4enZ8AszLlaZnGVMqqlKd85tp50jV5V-e1TLDJynrOqwXndTI0ZVVy3vZFWdc1z3i9KHCei7ItK5GVosoT1Qgucl7zitdZLuq0rirZZX1RVV1f1HnL5hxHqXSq9X5MrdsmyvuATVkUiyLRcoPax-IhxHOHmRBM3DEhDB4g7phmimXimglotglbz-ZcK0_-Ck2KdCxFL6CK5fNy8_aWPWywtSPCOEViupk4OEUJuyQ43QxEu5jhYsXEaqtoCJu0tSMTq4n9_DfbOfuILTGxij57JlbxoD8DAAD__yCYIXY">