[ << ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
Macro parameters should have all-uppercase names.
ttl
, sum
, avg
, min
,
max
, ... go at the end of names following an underscore.
(See the table of abbreviations below.)
Do not use num
as a qualifier, since it can mean "number of the
current item" or "number of items". Use cur
or idx
for
the former meaning, cnt
for the latter.
parse_DATA_LIST()
as a function to parse a PSPP DATA LIST
construct. Do not use such a capitalized keyword as the only component
of a name.
done
, error
, found
, success
, ....
There is an implied, unwritten "is": (is_)done
, etc.
not_found
.
x0
and x1
.
_p
suffix indicates a boolean test for the condition described
by the rest of the name. (This comes from Lisp.)
Otherwise, try to avoid abbreviations.
amount amt
average avg
buffer buf
calculate calc
command cmd
compare cmp
count cnt
current cur
decrement dec
destination dst
enumeration enum
expression expr
function func
increment inc
index idx
length len
lexical lex
maximum max
minimum min
number -- Don't use. Substitute cur
oridx
for an index,cnt
for a count.pointer ptr
Don't use in names of actual C pointers, only in the names of array indexes, etc., that act as pointers. previous prev
procedure proc
quantity qty
record -- Don't use. source src
statement stmt
structure -- Don't use. table tbl
target -- Use "destination" ( dst
) instead.temporary tmp
variable var
[ << ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |