Remove K&R stuff: never use it in new code.
Remove how to format K&R stuff. The project hasn't been using it in new code for a long time. It's so obsolete, we don't need a statement to never use it. Add a statement requesting that comments about parameters be preserved when converting to ASNI style, per Kirk. Differential Revision: https://reviews.freebsd.org/D14051
This commit is contained in:
parent
888651fcd9
commit
c3d171bd18
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=330699
@ -763,17 +763,9 @@ do not roll your own.
|
||||
}
|
||||
.Ed
|
||||
.Pp
|
||||
Old-style function declarations look like this:
|
||||
.Bd -literal
|
||||
static char *
|
||||
function(a1, a2, fl, a4)
|
||||
int a1, a2; /* Declare ints, too, do not default them. */
|
||||
float fl; /* Beware double vs. float prototype differences. */
|
||||
int a4; /* List in order declared. */
|
||||
{
|
||||
.Ed
|
||||
When converting K&R style declarations to ANSI style, preserve
|
||||
any comments about parameters.
|
||||
.Pp
|
||||
Use ANSI function declarations unless you explicitly need K&R compatibility.
|
||||
Long parameter lists are wrapped with a normal four space indent.
|
||||
.Pp
|
||||
Variable numbers of arguments should look like this:
|
||||
|
Loading…
Reference in New Issue
Block a user