Site hosted by Angelfire.com: Build your free website today!
Table of Contents Previous Next

1.11 The Standard Headers: <stddef.h>

The header <stddef.h> contains type and macro definitions of use to a freestanding program that do not belong in <float.h>, <limits.h>, and <stdarg.h>.

Some of these types and macros are also defined in other headers.


<stddef.h> Types

ptrdiff_t
A signed integral type of the result of subtracting two pointers.
size_t
The unsigned integral type of the result of the sizeof operator.
wsize_t
An integral type whose range of values can represent distinct codes for all members of the largest character set specified amongst the supported locales.

<stddef.h> Macros

NULL
Expands to an implementation-defined null pointer constant.
offsetof(type, member-designator)
Expands to an integral constant expression that has type size_t, the value of which is the offset in bytes, to the structure member (designated by member-designator), from the beginning of its structure (designated by type).  The member-designator shall be such that given
     static type t;
then the expression &(t.member-designator) evaluates to an address constant.  If the specified member is a bit-field, the behaviour is undefined.

Table of Contents Previous Next

Last modified: Fri May 12 13:15:54 2000