Alexandre Julliard wrote:
Michael Stefaniuc mstefani@redhat.com writes:
Actually it's not a cast. It's a heuristic that the compiler has to make to detect a NULL pointer. The best heuristic for this is (char *) 0.
Duh ... that should have been (void *) 0.
There's no heuristic involved here, the assignment is clearly to a pointer, and 0 is a perfectly valid null pointer, no cast is needed.
I was talking more in general and not about this concrete case here. Both "0" and "(void *) 0" work here; which to use is a matter of style and thus good for a flame war. But i don't care too much to start one ;)
bye michael