From: Hao Liu Date: Wed, 10 Dec 2014 07:25:08 +0000 (+0800) Subject: docs: Fix missing curly braces X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=0d60a03094282942be35225d52f14ae2cc73691f;p=libvirt.git docs: Fix missing curly braces Signed-off-by: Hao Liu --- diff --git a/HACKING b/HACKING index 884e78cadd..94d9d2cb45 100644 --- a/HACKING +++ b/HACKING @@ -383,8 +383,9 @@ single-'statement' loop: each has only one 'line' in its body. single_line_stmt(); // {} is optional (not enforced either way) while (expr1 && - expr2) // multi-line, at same indentation, {} required + expr2) { // multi-line, at same indentation, {} required single_line_stmt(); + } However, the moment your loop/if/else body extends on to a second line, for whatever reason (even if it's just an added comment), then you should add diff --git a/docs/hacking.html.in b/docs/hacking.html.in index a73b1e0c85..53786b7d2a 100644 --- a/docs/hacking.html.in +++ b/docs/hacking.html.in @@ -481,8 +481,9 @@
   while (expr1 &&
-         expr2)           // multi-line, at same indentation, {} required
+         expr2) {         // multi-line, at same indentation, {} required
       single_line_stmt();
+  }