-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Chuck,
On 10/8/2009 7:24 PM, Caldarale, Charles R wrote: > char array[6]; ... > sizeof array returns 6 This is what I was describing. The Wikipedia article states (I don't have my K&R book in front of me... besides, it wouldn't cover this case, anyway) that C99 allows /dynamic/ size determination: " sizeof is generally a compile-time operation, although in C99 it can be used at run-time to find the size of a variable length array. " Oddly, this statement is contradicted without qualification immediately below: " Since argv is a pointer to an array rather than an array itself, sizeof(argv) is equivalent to sizeof(char **) — that is, the size of the pointer type of argv. It will not be the size of the array to which argv points (which consists of a series of char* pointers). " > sizeof (struct string) returns 4 (usually; sometimes 8) - the length of the > int Wouldn't this yield (not "return" :) sizeof(int) + sizeof(char*)? - -chris -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkrOd7sACgkQ9CaO5/Lv0PCE2QCfX9y5QoZX8bhd1+Z24e5wmLTq 8eQAoJ4MxvuEiCC/Y7EF/3kTUsT012PP =ngEg -----END PGP SIGNATURE----- --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org