Re: [PATCH 3/3] configure: Use 0 instead of NULL because NULL isn't defined.

2007-10-23 Thread David Laight
On Sat, Oct 20, 2007 at 11:12:10AM +0200, Alexandre Julliard wrote: > Michael Stefaniuc <[EMAIL PROTECTED]> 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. (char *)0 is bad, 0 is ok, as

Re: [PATCH 3/3] configure: Use 0 instead of NULL because NULL isn't defined.

2007-10-20 Thread Juan Lang
> 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 ;) I'll point out that for the case at hand, a configure test, code readability is probably not a very important goal. As Ken points out, the configure

Re: [PATCH 3/3] configure: Use 0 instead of NULL because NULL isn't defined.

2007-10-20 Thread Michael Stefaniuc
Alexandre Julliard wrote: > Michael Stefaniuc <[EMAIL PROTECTED]> 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

Re: [PATCH 3/3] configure: Use 0 instead of NULL because NULL isn't defined.

2007-10-20 Thread Stefan Dösinger
Am Samstag, 20. Oktober 2007 00:36:13 schrieb Ken Thomases: > On Oct 19, 2007, at 5:24 PM, Stefan Dösinger wrote: > > Am Freitag, 19. Oktober 2007 23:18:51 schrieb Ken Thomases: > >> This makes the test test the proper thing on Mac OS X. It still > >> fails, but > >> for a good reason. > >> --- >

Re: [PATCH 3/3] configure: Use 0 instead of NULL because NULL isn't defined.

2007-10-20 Thread Alexandre Julliard
Michael Stefaniuc <[EMAIL PROTECTED]> 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. There's no heuristic involved here, the assignment is clearly to a pointer, and 0 is a perfectly valid nu

Re: [PATCH 3/3] configure: Use 0 instead of NULL because NULL isn't defined.

2007-10-19 Thread Michael Stefaniuc
Ken Thomases wrote: > On Oct 19, 2007, at 5:24 PM, Stefan Dösinger wrote: > >> Am Freitag, 19. Oktober 2007 23:18:51 schrieb Ken Thomases: >>> This makes the test test the proper thing on Mac OS X. It still >>> fails, but >>> for a good reason. >>> --- >>> configure.ac |6 +++--- >>> 1 f

Re: [PATCH 3/3] configure: Use 0 instead of NULL because NULL isn't defined.

2007-10-19 Thread Ken Thomases
On Oct 19, 2007, at 5:24 PM, Stefan Dösinger wrote: > Am Freitag, 19. Oktober 2007 23:18:51 schrieb Ken Thomases: >> This makes the test test the proper thing on Mac OS X. It still >> fails, but >> for a good reason. >> --- >> configure.ac |6 +++--- >> 1 files changed, 3 insertions(+),

Re: [PATCH 3/3] configure: Use 0 instead of NULL because NULL isn't defined.

2007-10-19 Thread Stefan Dösinger
Am Freitag, 19. Oktober 2007 23:18:51 schrieb Ken Thomases: > This makes the test test the proper thing on Mac OS X. It still fails, but > for a good reason. > --- > configure.ac |6 +++--- > 1 files changed, 3 insertions(+), 3 deletions(-) > -char *name=NULL; > +char *name=0; Shou