how to tell clang-format not put ';' to new line?

33 Views Asked by At

My C code like this:

while(true);

for(int i=100;i--;);

if i use clang-format, it will be replace like this:

while(true)
;

for(int i=100;i--;)
;

I just try this, but it do not work: AllowShortBlocksOnASingleLine: Always AllowShortCaseLabelsOnASingleLine: AllIfsAndElse

I don't want the ';' on newline, how to do it?

0

There are 0 best solutions below