<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/76563>76563</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[clang-format] Do not move to new line after assignment operator
</td>
</tr>
<tr>
<th>Labels</th>
<td>
clang-format
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
MaJerle
</td>
</tr>
</table>
<pre>
If the line is too long, part of it will get to new line, like so:
```c
s_command.AddressDtrMode =
(Rate == MX25LM51245G_DTR_TRANSFER) ? HAL_OSPI_ADDRESS_DTR_ENABLE : HAL_OSPI_ADDRESS_DTR_DISABLE;
```
While some longer code may get restructured to:
```c
s_command.DummyCycles =
(Mode == MX25LM51245G_SPI_MODE)
? 0U
: ((Rate == MX25LM51245G_DTR_TRANSFER) ? DUMMY_CYCLES_REG_OCTAL_DTR : DUMMY_CYCLES_REG_OCTAL);
```
Is it possible to force format to format long lines like below example?
```c
s_command.AddressDtrMode = (Rate == MX25LM51245G_DTR_TRANSFER)
? HAL_OSPI_ADDRESS_DTR_ENABLE
: HAL_OSPI_ADDRESS_DTR_DISABLE;
s_command.DummyCycles = (Mode == MX25LM51245G_SPI_MODE)
? 0U
: ((Rate == MX25LM51245G_DTR_TRANSFER) ? DUMMY_CYCLES_REG_OCTAL_DTR : DUMMY_CYCLES_REG_OCTAL);
//Or even like this
s_command.DummyCycles =
(Mode == MX25LM51245G_SPI_MODE)
? 0U
: ((Rate == MX25LM51245G_DTR_TRANSFER)
? DUMMY_CYCLES_REG_OCTAL_DTR
: DUMMY_CYCLES_REG_OCTAL);
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJzEVVuPszYQ_TXmZbQR2OGSBx7YEL6mSjZVsqt2n5CBIaE1OLLNbvPvK8N2L1H21laqFTkYnxlmzpzRcK2bfYcYE_-a-KnDe3OQKl7zn1EJdApZneJlDeaAIJoOodFgpAQhuz2hczhyZUDW0Bh4bISAPRowEjp8HOAWIpo_ELQkLCFuSty_98Adf-V4BgDQeSnblnfVJKkqhVqnRq1lhUBY-oKyi9Boy814wVJY_0b91dr36NT_kae32_x2m9zsssWW0BkQlsFPySrf7H5Z5kmabhe73QBa3CTXqwUQlly-T5c7CyDs-izk13n8emiETa_FgRNUUNqIW34auFCojepL0yuswFgS4OsspH3bnuanUqC-SMEzN-cU2EzWm3RB6Oyt0WDIMnDvLr1PrNPvUpverdf3-fx-vlrs8u3iR76Z3yYrCx08Xr62gX1I61JbSR2l1k0h0EqqlqpEu7fcPJ3tkyV9kJoehVagkI-Af_L2KJCw7EO2PxLcdzT25O4TpT2jvqq38yDP9PBNCbxX90vr_9LCKOyM0GyjAB-wG4tqDo3-jI1_0x3_XUu8cvg-GZdr8I-6xaliVs3YjDsYe6HLIt_1aeAc4iryQgyK0C2wdAMW-HU99aqwLjH0onDGnCamLmUepTPPm0bTYBKVjEWsDqOg9uuSUzJ1seWNmAjx0E6k2juN1j3GYeAHzBG8QKGHqUFpKXi3vxo7klBq54iKrdlV0e81mbqi0Ua_ODKNEcPEeWPop5BK6KSBVj7g6zECvDaoYJxVLXYG5BEVN1I5vRLxwZijtvNlUM6-MYe-mJSyJTSzn3z6uzoq-TuWhtBsSEQTmg25_BUAAP__el3xcQ">