Only the outline of this manual has been written -- it needs a LOT of work!!
The basic goal behind choosing names in the STAMP function library is for the name to convey information about what it represents. This is achieved in two ways: striving for a descriptive name rather than a short cryptic abbreviated name, and following a different pattern of capitalization for each type of name.
Preprocessor macro names are written entirely in capital letters. If
the name requires more than one word for an adequate description, the
words are joined together with intervening underscore (
Data structure names consist of one or more capitalized words. If the name requires more than one word for an adequate description, the words are joined together without underscores, depending on the capitalization pattern to make them readable as separate words.
Variable names in the STAMP function library follow a modified form of the Hungarian naming convention described by Steve McConnell in his book Code Complete on pages 202-206.
Variable names have three parts: a lowercase type prefix, a descriptive name, and a scope suffix.
The type prefix has the following basic possibilities:
charbut sometimes a
enumor as a
long, or (rarely)
In addition, the basic types may be prefixed by these qualifiers:
The descriptive name portion of a variable name consists of one or more
capitalized words concatenated together. There are no underscores
_) separating these words from each other, or from the type
prefix. For the STAMP function library, the descriptive
name for global variables
The scope suffix has these possibilities:
The lack of a scope suffix indicates that a variable is declared within a function and exists on the stack for the duration of the current call.
Global function names in the STAMP function library have
two parts: a verb that is all lowercase followed by a noun phrase
containing one or more capitalized words. These pieces are
concatanated without any intervening underscores (
_). For the
STAMP library functions, the noun phrase section
Given the discussion above, it is easy to discern at a glance what type of item each of the following names refers to.
This document was generated on 11 May 2000 using texi2html 1.55k.