size_t (was: A lint question)

Richard A. O'Keefe ok at quintus.uucp
Wed Nov 30 20:26:06 AEST 1988


In article <14750 at mimsy.UUCP> chris at mimsy.UUCP (Chris Torek) writes:
>In article <766 at quintus.UUCP> ok at quintus.uucp (Richard A. O'Keefe) writes:
>>size_t is an unsigned integral type (except in BSD systems, where it's "int").

>The only `size_t' appearing in any 4BSD release is in <sys/types.h>.
That's the one I meant.

>The point, however, is that the size_t found in
>4BSD is not related to the size_t found in the dpANS, and hence not
>conformant.

"man types" in SunOS 3.2 lists the types and explains some of them, but
not size_t.  Since one of the differences between BSD and SysV is that
read() and write() take "unsigned" length parameters in SysV but "int"
ones in BSD, while size_t is "unsigned int" in V.3's <sys/types.h> but
"int" in 4.2's <sys/types.h>, I assumed that it was the size_t of the
dpANS.  I'm sorry to hear that this was just good luck.  What *is*
the size_t in <sys/types.h> for, then?



More information about the Comp.lang.c mailing list