News for hackers. Stuff that matters.
Re:Xcode 4 ships a buggy compiler by Someone on Saturday December 31, 2011 @04:40AM (#3410563)
"the case of alloca'ing 0 bytes. I __could__ see an argument for expecting that to be always null"

??? I would expect that it always succeeds. Rationale: if, at some time and place, alloca(n) succeeds, I expect that any alloca asking for less space would succeed, too.

Re:Xcode 4 ships a buggy compiler by dextorious on Saturday December 31, 2011 @05:10AM (#3410613)
so alloca(-1) would succeed too, right?
Re:Xcode 4 ships a buggy compiler by FooBarWidget on Saturday December 31, 2011 @05:18AM (#3410623)
No. According to the OS X and Linux man pages 'size' has type 'size_t'. It is undefined whether size_t is signed.
Re:Xcode 4 ships a buggy compiler by Someone on Saturday December 31, 2011 @08:16AM (#3410818)
alloca takes a sixe_t. I think size_t is unsigned. http://stackoverflow.com/questions/1089176/is-size-t-always-... seems to agree with that (correction welcome)