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

    <tr>
        <th>Summary</th>
        <td>
            clang-format inconsistency when using #else
        </td>
    </tr>

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

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

    <tr>
      <th>Reporter</th>
      <td>
          Tobias-Glimmerfors
      </td>
    </tr>
</table>

<pre>
    Minimal example to reproduce weird behavior:
C code:
```C
static void f()
{
#if 1
  VAR(char) *im;
#else
  VAR(char) *im;
#endif
}
```

.clang-format:
```
Macros:
  - VAR(type)=type
```

This gets formatted as:
```C
static void f() {
#if 1
  VAR(
  char) *im;
#else
  VAR(char) *im;
#endif
}
```

If I change the `#if 1` to `#if 0`, I get the following instead, which is what I want:
```C
static void f() {
#if 0
  VAR(char) *im;
#else
  VAR(char) *im;
#endif
}
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJy8U01vozAQ_TXmMkpkDBQ4cEgbZZVDL6tq78YeYFbGjmxTtv9-BaHpfqt7qYTAj5nxGz-_kSFQbxEbVtyz4pjIKQ7ON0-uJRl2nwyNI_rO-ZC0Tr80j2RplAbwmxwvBiE68HjxTk8KYUbyGloc5DM5z7ID40fGDw-gnMYbZHf8-jxccYgykoJnRxo6Jiom6i2xvN8WIqMO0isA-HL4zESlBumZqIGJA40se0tFE_C9qVZT90p2_KW9Da7vvTLS9rvO-VHG309yhY9SeRduUYDdxh9fLricKjuuq7_TPA0UoMcY4MoUUYMM_6Mc_Fu0V_Sh4p07OC-MtkeIA8IS3pq744uDbj_WSvEA50WENbdzxriZbA9kQ0Spl_A8kBqAAsyDjHCGWdo_XMr7ReIf7KxEN5mus1om2KQlr2uelUWVDI3kMmvTKk9TXbZZK8uyVFrztm1Fl9VFnlAjuMh5xqs0S4ui2staFyhqUcsCS1VylnMcJZm9Mc_j3vk-oRAmbKo8L8vEyBZNWEddiJ8sLcQy_L5Zynbt1AeWc0MhhreNIkWDzY9VQFY5GyhEtOoF5gEtTGG5rE2sZPKmGWK8rB4WJyZOPcVhavfKjUyclr23z-7i3VdUkYnT2nFg4rQ2_T0AAP__vS1IQg">