home  

nl_after_do

Properties

  Category: Newline adding and removing options
      Type: multiple (ignore add remove force)
   Default: ignore

Description

Add or remove blank line after 'do/while' statement.

Examples

raw CPP code nl_after_do=false nl_after_do=true nl
nl_after_do=true
void f(int a){ do{ g(a); }while(a); g(a); do g(i); while(a); do{ g(a); }while(a); } void f(int a){ do{ g(a); }while(a); g(a); do g(i); while(a); do{ g(a); }while(a); } void f(int a){ do{ g(a); }while(a); g(a); do g(i); while(a); do{ g(a); }while(a); } void f(int a){ do{ g(a); }while(a); g(a); do g(i); while(a); do{ g(a); }while(a); }
 

Info

  The blank line is added if the 'do...while();' statement is followed by another statement, not by a '}'.
  This option doesn't apply to 'while()...'.
  Looks like the tracking is not working
  Edited by JEAYNE

Not the best code for this option? See how to improve the .uds file used to generate these examples.