# <stddef.h> <stddef.h> # `` * * * Include the standard header **``** to define several types and macros that are of general use throughout the program. The standard header `` is available even in a [freestanding implementation](https://docs.qualcomm.com/doc/80-N3040-23/topic/c_lib_over.html#freestanding%20implementation). /* MACROS */ #define NULL [0 in C++] #define offsetof(s-type, mbr) /* TYPES */ typedef si-type ptrdiff_t; typedef ui-type size_t; typedef i-type wchar_t; [keyword in C++]Copy to clipboard ## `NULL` #define NULL [0 in C++]Copy to clipboard The macro yields a null pointer constant that is usable as an [address constant expression](https://docs.qualcomm.com/doc/80-N3040-23/topic/c_express.html#address%20constant%20expression). ## `offsetof` #define offsetof(s-type, mbr) Copy to clipboard The macro yields the offset in bytes, of type [`size_t`](https://docs.qualcomm.com/doc/80-N3040-23/topic/c_stddef.html#size_t), of member `mbr` from the beginning of structure type `s-type`, where for `X` of type `s-type`, `&X.mbr` is an [address constant expression](https://docs.qualcomm.com/doc/80-N3040-23/topic/c_express.html#address%20constant%20expression). ## `ptrdiff_t` typedef si-type ptrdiff_t;Copy to clipboard The type is the signed integer type `si-type` of an object that you declare to store the result of subtracting two pointers. ## `size_t` typedef ui-type size_t;Copy to clipboard The type is the unsigned integer type `ui-type` of an object that you declare to store the result of the [*sizeof*](https://docs.qualcomm.com/doc/80-N3040-23/topic/c_express.html#sizeof%20operator) operator. ## `wchar_t` typedef i-type wchar_t; [keyword in C++]Copy to clipboard The type is the integer type `i-type` of a [wide-character constant](https://docs.qualcomm.com/doc/80-N3040-23/topic/c_charset.html#wide-character%20constant), such as `L'X'`. You declare an object of type `wchar_t` to hold a [wide character](https://docs.qualcomm.com/doc/80-N3040-23/topic/c_charset.html#Wide-Character%20Encoding). * * * See also the **[Table of Contents](https://docs.qualcomm.com/doc/80-N3040-23/topic/c_index.html#Table%20of%20Contents)** and the **[Index](https://docs.qualcomm.com/doc/80-N3040-23/topic/_c_index.html)**. *[Copyright](https://docs.qualcomm.com/doc/80-N3040-23/topic/c_crit_pjp.html) © 1992-2006by P.J. Plauger and Jim Brodie. All rights reserved.* Last Published: Oct 06, 2026 Previous Topic Next Topic