Commit Graph

134 Commits

Author SHA1 Message Date
trasz
5b6a140b26 Restore comment describing /* NOTREACHED */, updated to match reality. 2011-01-07 08:34:12 +00:00
trasz
caf16f9aea Get rid of bad advice regarding /* NOTREACHED */. Compilers don't
really need it (one can use __dead2 instead), and style(9) was not
even consistent with itself in this regard.
2011-01-06 08:33:48 +00:00
uqs
8ae3afcfad mdoc: drop redundant .Pp and .LP calls
They have no effect when coming in pairs, or before .Bl/.Bd
2010-10-08 12:40:16 +00:00
cperciva
b2f9946422 Note that internal_underscores should be used in identifier names rather
than camelCase or TitleCase.

According to grep and my checked-out source tree, we're currently at
3733379 internal_underscores, 93024 camelCases, and 80831 TitleCases;
so this commit is merely documenting existing practice.
2010-06-27 02:30:19 +00:00
des
ffcddec75d Boot out <sysexits.h> once and for all.
MFC after:	1 week
2008-12-17 13:01:19 +00:00
rwatson
272e95193b Revert r184509: don't encourage the use of sysexits.h with err() and
errx(),, as there seems to be a general preference against this
practice.

Suggested by:	bde, des, jhb
2008-11-27 08:42:58 +00:00
rwatson
06bee05bb5 In style(9) examples of err() and errx(), use sysexits(3) errors rather
than returning 1.

Submitted by:	Bruce Cran <bruce at cran dot org dot uk>
MFC after:	3 days
2008-10-31 14:47:15 +00:00
danger
b35e10e860 Back-out my previous change. See the thread at
http://lists.freebsd.org/pipermail/cvs-all/2008-July/263779.html
2008-07-10 11:24:41 +00:00
danger
7c6cdcc163 - nested functions are a GCC extensions and should not be used
Submitted by:	gahr
MFC after:	3 days
2008-07-09 14:04:28 +00:00
obrien
d325c7e921 Add to the history section. 2008-01-27 03:58:22 +00:00
grog
237cf99d30 "redacted" replaced for clarity. 2008-01-05 21:39:21 +00:00
joel
350e76dd56 Line break before "All rights reserved" in the license example.
Reveiwed by:	bde, rwatson
2007-01-28 20:51:04 +00:00
obrien
b891fb48a3 Clarify case body indention. 2006-11-26 21:22:49 +00:00
hmp
6b954a1933 Use 'manual page' instead of 'man page' for consistency.
Approved by:	re (hrs)
2005-06-28 20:15:19 +00:00
obrien
80ba7fc395 Clarify the header. 2005-05-17 15:03:50 +00:00
ru
3449204d8b Recover the original Berkeley RCS id, and fix the description of
format for source files when it comes to $FreeBSD$.
2005-05-17 14:20:42 +00:00
keramida
dea3063720 Remove a duplicate 'comment' to fix the syntax of a sentence. 2005-05-17 01:25:57 +00:00
ru
114ea39c76 Fixed the misplaced $FreeBSD$. 2005-02-09 18:07:17 +00:00
ru
5391cb9508 Add a few colons.
Submitted by:	Joel Dahl
2005-01-26 20:50:52 +00:00
ru
007d29aae3 Nits. 2005-01-13 09:33:06 +00:00
keramida
587dd95b4b Fix typos and add .Pp after the end of a display to separate the
displayed text from the paragraph right after it.
2005-01-09 22:49:24 +00:00
imp
c00855c99f Clarify /*- convention. 2005-01-05 21:27:01 +00:00
imp
a9e88e95f3 A large majority of the source files in the tree start their license
and copyright statements in a comment that begins with /*-.  Document
this tradition.  A strict adherence to this rule will help resellers
that wish to publish all copyright notices, generated automatically
from the tree.  There are too many variant licenses to do it purely
by more complicated pattern matching.
2005-01-05 19:16:01 +00:00
dds
dc842a5b49 Clarify the structure element size ordering.
Obtained from:	OpenBSD style.9 1.38
2004-12-02 23:20:17 +00:00
ru
1cf1598667 Mechanically kill hard sentence breaks and double whitespaces. 2004-07-03 18:29:24 +00:00
bde
2e35fb1a4c Fixed a style bug in the previous commit. 2004-06-26 09:02:44 +00:00
obrien
2194f33c4e Embellish the getopt(3) example with mixed case.
Reviewed by:	bde
2004-06-26 05:15:00 +00:00
ru
aa52a5a900 Assorted markup, spelling, and grammar fixes. 2004-06-16 08:33:57 +00:00
le
0e1c766f8f What world have we come to when even style(9) isn't unfailable:
correct style nit in an example.
2004-06-13 21:24:56 +00:00
fanf
22656dea02 Better English usage.
Submitted by: wollman
2003-11-12 10:53:52 +00:00
fanf
168e47de63 Clarify the rule about structure typedefs being discouraged, following
a discussion on src-committers.
2003-11-10 14:32:13 +00:00
imp
9d6689c4a7 Two minor fixes:
o It is the /usr/include files, not the /usr include files.
o Document the practice of converting to the c99 standard uintXX_t
  form from the older, but non-standard, BSD-style u_intXX_t.  This
  has been going on in the tree for a while now, and I've heard other
  developers also state that this conversion is happening.  Note also
  that this is a slow process and should be treated like whitespace
  changes.
2003-09-27 22:17:37 +00:00
ru
1c23ef339b mdoc(7): Use the new feature of the .In macro. 2003-09-08 19:57:22 +00:00
trhodes
4d37b34b62 Xref sytle.Makefile(5).
PR:	51183
2003-04-26 15:37:39 +00:00
jhb
81073fb53b Revert previous commit which accidentally snuck in with some unrelated
changes.

Reported by:	bde
2003-03-25 19:46:55 +00:00
jhb
506e1c7087 Remove obsolete at_fork() and at_exit() manpages. Curiously, at_exec()
didn't have a manpage.

Reminded by:	ru
2003-03-25 16:36:47 +00:00
schweikh
fec6546e12 english(4) police. 2002-12-27 12:15:40 +00:00
ru
6d3a461a4f mdoc(7) police: scheduled sweep.
Approved by:	re
2002-11-29 11:39:20 +00:00
ru
10c48e457c mdoc(7) police:
Revert to using the .Tn POSIX and .Tn ANSI instead of \*[Px] and \*[Ai]
strings; using these strings is unsafe in troff mode, as they include a
change in a font size.

Approved by:	re
2002-11-26 17:55:41 +00:00
rwatson
c60e6be0f4 Further clarifications of the #ifdef/#if/#elif/#endif style information,
largely submitted by bde.  Return our exemption of the #ifdef lint
comments since the exemption is intended to handle a particularly
common current case without mandating change.  Improve language and
spelling, and slightly clarify the notions associated specifically
with #elif.

Obtained from:	bde
2002-11-01 16:20:31 +00:00
rwatson
d5b5077e34 Clarify style(9) WRT comments following #endif, #else.
The closing comment is required only for long conditionally defined
code sections, with the exception of lint cases.  Attempt to document
also the logic for using '!' before the SOMETIMESSOMETHGINGHERE.
The goal of these comments is to make complex cases more
comprehensible, not to require them in all cases.  The rules here are
derived from behavior used in 90+% of the kernel source code.

Reviewed by and discussed with:	jhb, bde, mike
2002-10-28 19:33:22 +00:00
robert
fef1f5b972 Add a paragraph which should clarify the separation of asterisks
and adjacent tokens in declarations.
The added text was originally a single sentence I wrote and which
was heavily modified and extended by Bruce Evans.

This clarification attempt originates from differing usage of the
'restrict' type-qualifier.
Although various documents documents dicussing the C Programming
Language put a space between an asterisk and the 'restrict' keyword,
including the C99 standard (at least the n869.txt draft) and other
ISO/IEC JTC1/SC22/WG14 documents, the IEEE Std 1003.1-2001 document
does not separate them.

Discussed with:		bde
Requested by:		tjr
Separation using a single space also liked by:	mike
2002-09-10 14:48:38 +00:00
fanf
f21645dfc2 Remove a sentence about wrapping macro definitions in bare braces,
which became wrong after using do { } while (0) became recommended.
Move the definition of what braces are to their new first occurrence.

Reviewed by:	bde
2002-09-10 10:54:39 +00:00
robert
97acf1a793 Expand a contraction in the text of style(9) for consistency.
Do not touch contractions in comments of code examples because
their usage seems to be justified by space contraints.
2002-09-06 10:53:57 +00:00
imp
9cf789ad20 Suggest that function prototypes in kernel headers be alphabetical,
unless there's a compelling reason to deviate.

Submitted by: Don Lewis
Suggestion not objected to by: developers@
2002-08-21 06:58:21 +00:00
ru
506db62790 mdoc(7) police: nit. 2002-08-13 14:52:41 +00:00
imp
b28c5c5701 Clarify the sizeof(var) rule. This is the result of the consensus in
arch@ between myself, bde and markm.  I kept the parts that all of us
agreed to, and omitted some more extensive text that I'd originally
wanted.
2002-07-25 00:30:24 +00:00
imp
18542852db Clarify version 1.68 to more accurately describe the intent of the change to
try to avoid ambiguous cases in the future.

Wording approved by: julian (early draft), grog, rwatson, wes and maybe other
members of core I'm forgetting.
2002-07-02 01:39:35 +00:00
asmodai
86ad61838f Correct two syntax mistakes.
Fix overflowing right side, so that the && operator fits on the same line.
2002-04-14 19:52:42 +00:00
asmodai
26c7f25d91 Remove extraneous newline. 2002-04-14 19:33:07 +00:00