summaryrefslogtreecommitdiff
path: root/share
diff options
context:
space:
mode:
authorHugh Graham <hugh@cvs.openbsd.org>2003-01-21 08:12:42 +0000
committerHugh Graham <hugh@cvs.openbsd.org>2003-01-21 08:12:42 +0000
commitf99af9b0d2050135e3cfcb0b1f2e6d02919970fb (patch)
tree98db956b8530759319b49e13bcff538048e45e00 /share
parent38fc7792fb94444ce1fe52060f4eacbe27cab241 (diff)
Style, punctuation and grammar fixups from Ted Unangst on bugs@.
Diffstat (limited to 'share')
-rw-r--r--share/man/man9/style.912
1 files changed, 6 insertions, 6 deletions
diff --git a/share/man/man9/style.9 b/share/man/man9/style.9
index 989fff22df4..85c4dbeb9a2 100644
--- a/share/man/man9/style.9
+++ b/share/man/man9/style.9
@@ -22,7 +22,7 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.\" $OpenBSD: style.9,v 1.28 2002/10/11 22:15:02 marc Exp $
+.\" $OpenBSD: style.9,v 1.29 2003/01/21 08:12:41 hugh Exp $
.\"
.Dd June 18, 2001
.Dt STYLE 9
@@ -268,7 +268,7 @@ call and the switch statement, unless
parts of the switch cascade.
Elements in a switch statement that cascade should have a FALLTHROUGH comment.
Numerical arguments should be checked for accuracy.
-Code that cannot be reached should have a NOTREACHED comment,
+Code that cannot be reached should have a NOTREACHED comment.
.Bd -literal -offset 0i
while ((ch = getopt(argc, argv, "abn:")) != -1)
switch (ch) { /* Indent the switch. */
@@ -374,11 +374,11 @@ or
.Sq \&)
characters.
.Bd -literal -offset 0i
- if (error = function(a1, a2))
+ if ((error = function(a1, a2)))
exit(error);
.Ed
.Pp
-Unary operators don't require spaces, binary operators do.
+Unary operators don't require spaces; binary operators do.
Don't use parentheses unless they're required for precedence, the statement
is confusing without them, or the compiler generates a warning without them.
Remember that other people may be confused more easily than you.
@@ -412,7 +412,7 @@ ANSI style function declarations should go in an include file such as
.Dq Pa extern.h .
If a line overflows reuse the type keyword.
.Pp
-Be careful to not obfuscate the code by initializing variables in
+Be careful not to obfuscate the code by initializing variables in
the declarations.
Use this feature only thoughtfully.
DO NOT use function calls in initializers!
@@ -443,7 +443,7 @@ Use of the
.Dq register
specifier is discouraged in new code.
Optimizing compilers such as gcc can generally do a better job
-of choosing which variables to be placed in registers to improve
+of choosing which variables to place in registers to improve
code performance.
The exception to this is in functions containing assembly code where the
.Dq register