I'm not the one who attempted to correct code that was correct in the first place. Nor am I the one who linked to a FAQ that says "use whichever you like provided you are aware of the issues" as evidence that my valid code was wrong. Just sayin'.Well, yeah, it is your problem; you've kind of made it a point to make it your problem by saying the problem is questionable or even imaginary.
I included compiler warnings and lint as a catch all for if the type of the pointer changes and the programmer is dumb enough to not check for type casts (those can be in other places than in front of malloc, by the way). But as far as the malloc and stdlib.h pairing goes, one does not need any tools other than a functioning brain to make sure stdlib.h is included.Just because you've never seen tools that misses an improper cast from `malloc' doesn't mean that such don't exist and aren't unfortunately prolific.
You seem to have a very poor opinion of every programmer on the planet if you think they are too stupid to include stdlib.h either before or after typing "malloc".
Outside of your perfect little world, casting malloc in C causes more harm than good.