ptrdiff_t(3type) — Linux manual page

NAME | LIBRARY | SYNOPSIS | DESCRIPTION | STANDARDS | HISTORY | SEE ALSO

ptrdiff_t(3type)                                        ptrdiff_t(3type)

NAME         top

       ptrdiff_t - count of elements or array index

LIBRARY         top

       Standard C library (libc)

SYNOPSIS         top

       #include <stddef.h>

       typedef /* ... */  ptrdiff_t;

DESCRIPTION         top

       Used for a count of elements, or an array index.  It is the
       result of subtracting two pointers.  It is a signed integer type
       capable of storing values in the range [PTRDIFF_MAX,
       PTRDIFF_MAX].

       The length modifier for ptrdiff_t for the printf(3) and the
       scanf(3) families of functions is t, resulting commonly in %td or
       %ti for printing ptrdiff_t values.

STANDARDS         top

       C11, POSIX.1-2008.

HISTORY         top

       C89, POSIX.1-2001.

SEE ALSO         top

       size_t(3type)

Linux man-pages (unreleased)     (date)                 ptrdiff_t(3type)

Pages that refer to this page: size_t(3type)