Change comment style to use @foo rather than FOO
... when referring to a function's parameter or a struct/union's member. The idea of using FOO comes from the GNU coding standards: The comment on a function is much clearer if you use the argument names to speak about the argument values. The variable name itself should be lower case, but write it in upper case when you are speaking about the value rather than the variable itself. Thus, "the inode number NODE_NUM" rather than "an inode". Upcasing names is problematic for a case-sensitive language like C, because it can create ambiguity. Moreover, it's too much shouting for my taste. GTK-Doc's convention to prefix the identifier with @ makes references to variables stand out nicely. The rest of the GTK-Doc conventions make no sense for us, however. Signed-off-by: Markus Armbruster <armbru@pond.sub.org>
This commit is contained in:
parent
5cff5022a9
commit
9f25de3dce
77 changed files with 633 additions and 633 deletions
|
@ -45,8 +45,8 @@ static char *weekday(char *str, int *wday);
|
|||
static char *daytime_range(char *str, int *from_min, int *to_min);
|
||||
|
||||
/*
|
||||
* Is week day WDAY (Sunday is 0) allowed by restriction DAYS?
|
||||
* If DAYS is not empty, it lists the allowed week day names. See
|
||||
* Is week day @wday (Sunday is 0) allowed by restriction @days?
|
||||
* If @days is not empty, it lists the allowed week day names. See
|
||||
* weekday() for syntax.
|
||||
*/
|
||||
int
|
||||
|
@ -65,8 +65,8 @@ is_wday_allowed(int wday, char *days)
|
|||
}
|
||||
|
||||
/*
|
||||
* Is day time DTIME (minutes since midnight) allowed by restriction TIMES?
|
||||
* If TIMES is not empty, it lists the allowed day time ranges. See
|
||||
* Is day time @dtime (minutes since midnight) allowed by restriction @times?
|
||||
* If @times is not empty, it lists the allowed day time ranges. See
|
||||
* daytime_range() for syntax.
|
||||
*/
|
||||
int
|
||||
|
@ -99,8 +99,8 @@ gamehours(time_t t)
|
|||
}
|
||||
|
||||
/*
|
||||
* Parse weekday name in STR.
|
||||
* On success assign day number (Sunday is 0) to *WDAY and return
|
||||
* Parse weekday name in @str.
|
||||
* On success assign day number (Sunday is 0) to *@wday and return
|
||||
* pointer to first character not parsed.
|
||||
* Else return NULL.
|
||||
* Abbreviated names are recognized, but not single characters.
|
||||
|
@ -135,8 +135,8 @@ weekday(char *str, int *wday)
|
|||
}
|
||||
|
||||
/*
|
||||
* Parse day time in STR.
|
||||
* On success store minutes since midnight in *MIN and return pointer
|
||||
* Parse day time in @str.
|
||||
* On success store minutes since midnight in *@min and return pointer
|
||||
* to first character not parsed.
|
||||
* Else return NULL.
|
||||
* Time format is HOUR:MINUTE. Initial whitespace is ignored.
|
||||
|
@ -170,8 +170,8 @@ daytime(char *str, int *min)
|
|||
}
|
||||
|
||||
/*
|
||||
* Parse a day time range in STR.
|
||||
* On success store minutes since midnight in *FROM and *TO, return
|
||||
* Parse a day time range in @str.
|
||||
* On success store minutes since midnight in *@from and *@to, return
|
||||
* pointer to first character not parsed.
|
||||
* Else return NULL.
|
||||
* Format is HOUR:MINUTE-HOUR:MINUTE. Initial whitespace is ignored.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue