strangest systems I've sent email from

Mouse mouse at Rodents-Montreal.ORG
Sun May 22 16:08:47 CDT 2016


>>>>       size_t foo = (size_t)-1;
>>>        size_t foo = -(size_t)1;
>>     size_t foo = (size_t)(-1);
>  Why bother?  Won't:
> 	size_t foo = ~0UL;
> do (~0ULL for C99)?

Only if size_t is no larger than unsigned long int (unsigned long long
int for the ULL version).  I don't think that's guaranteed.

					Mouse


More information about the cctalk mailing list