size_t

Geoff Rimmer geoff at cs.warwick.ac.uk
Wed Jun 21 10:10:05 AEST 1989


In article <845 at cbnewsl.ATT.COM> dfp at cbnewsl.ATT.COM (david.f.prosser) writes:
> Section 4.1.5 of the pANS:
> 
> 	The types [defined in <stddef.h>] are ...
> 
> 		size_t
> 
> 	which is the unsigned integral type of the result of the sizeof
> 	operator ...
> 
> It is also defined in <stdio.h>, <stdlib.h>, <string.h> and <time.h>.

Does this mean that size_t should be a #define rather than a typedef?
If it were a typedef, and I #include <stdio.h> AND <stdlib.h> (which
is a perfectly reasonable thing to do!), I would get errors.

> Dave Prosser	...not an official X3J11 answer...

	/---------------------------------------------------------------\
	|	GEOFF RIMMER						|
	|	email	: geoff at cs.warwick.ac.uk			|
	|		  geoff at uk.ac.warwick.cs			|
	|	address : Computer Science Dept, Warwick University, 	|
	|		  Coventry, England.				|
	|	PHONE	: +44 203 692320				|
	|	FAX	: +44 865 726753				|
	\---------------------------------------------------------------/

"First one I've had in twenty years and I won't be here to enjoy it."
	- Filthy, "Filthy Rich and Catflap" (best comedy series EVER)



More information about the Comp.std.c mailing list