sp_brace_else
Category: Spacing options Type: multiple (ignore add remove force) Default: ignore
Add or remove space between '}' and 'else' if on the same line.
raw CPP code | sp_brace_else=ignore | sp_brace_else=add | sp_brace_else=remove | sp_brace_else=force | space sp_brace_else=force |
---|---|---|---|---|---|
void fsp1(){if(a)b();else c();} void fsp2(){if(a){b();}else{c();}} | void fsp1(){ if(a) b(); else c(); } void fsp2(){ if(a){b();}else{c();} } | void fsp1(){ if(a) b(); else c(); } void fsp2(){ if(a){b();} else{c();} } | void fsp1(){ if(a) b(); else c(); } void fsp2(){ if(a){b();}else{c();} } | void fsp1(){ if(a) b(); else c(); } void fsp2(){ if(a){b();} else{c();} } | voidfsp1(){ if(a)b();elsec(); } voidfsp2(){ if(a){b();}else{c();} } |
Not the best code for this option? See how to improve the .uds file used to generate these examples.