News for hackers. Stuff that matters.
Re:Sizeof(char) is 1 by zbyszek on Monday September 06, 2010 @04:06AM (#1666218)
Personally, I like the idiom

  T* t = malloc( sizeof *t );
It's no big deal, but it's just one less thing to change if you need to change the type. (I once had to go through some code changing longs to ints to make it run on a 64-bit machine. Were the mallocs written this way it might have been a bit easier.)

And although I agree that his sizeof(char) rage is overblown, is the author's point about the zlib code not reasonable?

There are no comments on this comment yet.