aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWarner Losh <imp@FreeBSD.org>2015-07-06 20:10:47 +0000
committerWarner Losh <imp@FreeBSD.org>2015-07-06 20:10:47 +0000
commitabb14e5deda396bc3fb070ec80cb8a6ced66dd87 (patch)
tree207bb89898250df13d59732506233b127419d7cc
parent5e4f29c0376c9b62805fadf66830e2d0954a0422 (diff)
downloadsrc-abb14e5deda3.tar.gz
src-abb14e5deda3.zip
The results of the vote are in. This reflects that vote. Single
line statements inside of braces is recognized as an acceptable style. http://reviews.freebsd.org/V3 As always, this isn't license for wholesale change, etc.
Notes
Notes: svn path=/head/; revision=285219
-rw-r--r--share/man/man9/style.911
1 files changed, 6 insertions, 5 deletions
diff --git a/share/man/man9/style.9 b/share/man/man9/style.9
index ed65ac67b0ad..0af69aa4a271 100644
--- a/share/man/man9/style.9
+++ b/share/man/man9/style.9
@@ -26,7 +26,7 @@
.\" From: @(#)style 1.14 (Berkeley) 4/28/95
.\" $FreeBSD$
.\"
-.Dd January 7, 2010
+.Dd July 6, 2015
.Dt STYLE 9
.Os
.Sh NAME
@@ -503,13 +503,14 @@ Code which is unreachable for non-obvious reasons may be marked /*
.Pp
Space after keywords
.Pq Ic if , while , for , return , switch .
-No braces
+Two styles of braces
.Ql ( \&{
and
.Ql \&} )
-are
-used for control statements with zero or only a single statement unless that
-statement is more than a single line in which case they are permitted.
+are allowed for single line statements.
+Either they are used for all single statements, or
+they are used only where needed for clarity.
+Usage within a function should be consistent.
Forever loops are done with
.Ic for Ns 's ,
not