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

    <tr>
        <th>Summary</th>
        <td>
            [clang-format] Google-Style on sorting Includes moves them into comment & breaks code
        </td>
    </tr>

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

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

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

<pre>
    if you have a few includes commented out with a multiline comment (e.g. /* */) and then use clang-format on based google style to sort, it will move needed includes into the comment.

my includes pre sort:
```c++
#include <Log.h>
#include <Misc.h>
#include <TryCatch.h>
#include <robin_hood.h>

/* #include "DBO_Articles/DBO_Articles.h"
#include "DBO_Customers/DBO_Customers.h"
#include "DBO_PackagingOrders/DBO_PackagingOrders.h"
#include "DBO_PickingListRegistrations/DBO_PickingListRegistrations.h" */
#include "MySQL/MySQL.h"
#include "SQLJob.h"
#include "Time/Time.h"
#include "Worker/Worker.h"

#include <chrono>
#include <thread>
```

and after clang format sort:

```c++
#include <Misc.h>
#include <TryCatch.h>
#include <robin_hood.h>

/* #include "DBO_Articles/DBO_Articles.h"
#include <chrono>
#include <thread>

#include "DBO_Customers/DBO_Customers.h"
#include "DBO_PackagingOrders/DBO_PackagingOrders.h"
#include "DBO_PickingListRegistrations/DBO_PickingListRegistrations.h" */
#include "MySQL/MySQL.h"
#include "SQLJob.h"
#include "Time/Time.h"
#include "Worker/Worker.h"
```

as seen in the example, it moved the `chrono` and `thread` includes into the comment, which should not happen, since it breaks code

here is my clang format

```YAML
BasedOnStyle: Google
SpaceBeforeRangeBasedForLoopColon: false
ReferenceAlignment: Left
PointerAlignment: Left
AlignConsecutiveDeclarations: true
IndentWidth: 4
ColumnLimit: 0
BreakBeforeBraces: Attach
AllowShortFunctionsOnASingleLine: false
AllowShortLambdasOnASingleLine: false
DerivePointerAlignment: false
NamespaceIndentation: All
QualifierAlignment: Right

BraceWrapping:
  AfterControlStatement: true
 SplitEmptyFunction: false
```


</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJzsVsFu4zYQ_Rr6QsRQKNmxDjrI9rrYwmk28QJBTwuKGonTUKRAUk799wUlOXZSO2gvRQ8LGJbEefM4Q84bkjuHtQbIyGxJZusJ77w0NsPcGjEpTHnIsKIH01HJ90A5reCVohaqK8FRYZoGtIeSms7TV_SSctp0yqNCDUczJWwB03pKCdsQllPC8v4tpVyX1EvQtHNAheK6vqmMbbinRtOCOyhpbUytgDp_UEC9oc5YT9iKYphPKdqYPVANUEJ5igu1N4H4GMGURGsS5cN_czgBWwsDYzwayTwafoKwZfgNoyweXSiJV1tTTyWJv1yy3aMTV43f7WHFvZBXAdYUqH9IY8pzyAgc1-6EZ2y9fPiRW49CgSNsc_45lYSxv88x-Kw6500D9uj09v2p1zcuXniNun6w5cn3w-jnDCheUNdbdP4JanTeco9Gv1FdMfecx7K5QH1_2D1uCdv0z6sB7B63v5riqvk7NkDYJjyuYp6NfQFL2GZ4Ocdd2E0hrdHmylZ7aYGXJ-Ox7s7pgjx45cEO2qCjNt4X7D8u2_97af7LBftZ2v9VaV8sTUcdgKao-z4Lf_KmVTA25tCT-8ZOQ0UOmzqP-m5P5tG4kfPoer8OPK8ShaROmk6VVBtPJW9b0MHkUAsIExUW-Es4hko4D06CBYqONod3wrkomN_z--0wtAznzYPehZOGxDn9pT95Btuu5QKWUBkLT1zX0GM3xm6NaVdGGR0cKq7ciH-CCixoAbnCWvcpxTndQjUG8c2g9mCvWPvhldEOROdxD2sQih_rKc6pt904z1ddgvbPWHoZDMkwujKqa_QWG-yJx41bhsUaclhaLqCnyr3nQh6nVeZ1J431m06LfrYHne9Q1wq2qOFDjif4ljdFyT8Fr8HiHi6lfQb6jTfgwkoPafUJ90EqNQAeO66wwg8MT1jLd5vbp_dseduirt86JaV56KUro701aue5hyPDaUHprlXovzStPxwX4UOQF-UwKbO4TOOUT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