sp_before_constr_colon
Category: Spacing options Type: multiple (ignore add remove force) Default: add
Add or remove space before class constructor ':'. Default: add
MyClass::MyClass(int I):i(I){ //... };
raw CPP code | sp_before_constr_colon=ignore | sp_before_constr_colon=add | sp_before_constr_colon=remove | sp_before_constr_colon=force |
---|---|---|---|---|
MyClass::MyClass(int I):i(I){ //... }; MyClass::MyClass(char C) : c(C){ //... }; | MyClass::MyClass(int I): i(I){ //... }; MyClass::MyClass(char C) : c(C){ //... }; | MyClass::MyClass(int I) : i(I){ //... }; MyClass::MyClass(char C) : c(C){ //... }; | MyClass::MyClass(int I): i(I){ //... }; MyClass::MyClass(char C): c(C){ //... }; | MyClass::MyClass(int I) : i(I){ //... }; MyClass::MyClass(char C) : c(C){ //... }; |
Take care: the default is 'add' for both sp_before_constr_colon and sp_after_constr_colon Edited by JEAYNE
Not the best code for this option? See how to improve the .uds file used to generate these examples.