> Have just tried 9. Jan snapshot on AIX 4.1.5,
> compiles with gcc not with cc (fails in heaptuple.c), aix won't get
> defined though, did a -Daix

IBM compiler doesn't like the (void)NULLs in the heap_getattr and
StrNCpy macros.  Change to (bool)NULL in heap_getattr in include/
access/heapam.h and to (char)NULL in StrNCpy in include/c.h. In 6.2,
heap_getattr has (char)NULL (which is what bool is, so this worked),
but gcc gave warnings, so they were changed to _errors_ to "fix" them
for 6.3.

darrenk

Fri, 9 Jan 1998 10:35:07 -0500
darrenk@insightdist.com (Darren King)
Re: [HACKERS] column labels now with obligatory 'as'
> > Have just tried 9. Jan snapshot on AIX 4.1.5,
> > compiles with gcc not with cc (fails in heaptuple.c), aix won't get
> > defined though, did a -Daix
>
> IBM compiler doesn't like the (void)NULLs in the heap_getattr and
> StrNCpy macros.  Change to (bool)NULL in heap_getattr in include/
> access/heapam.h and to (char)NULL in StrNCpy in include/c.h. In 6.2,
> heap_getattr has (char)NULL (which is what bool is, so this worked),
> but gcc gave warnings, so they were changed to _errors_ to "fix" them
> for 6.3.

Ack! It looks to me like the StrNCpy macro needs (void *)NULL or just
NULL, not (void)NULL. Same with heap_getattr. Was this a workaround for
a compiler problem on another platform, or are we mixing type coersions?

                                                         - Tom


Fri, 09 Jan 1998 17:14:21 +0000
"Thomas G. Lockhart" <lockhart@alumni.caltech.edu>
Re: [HACKERS] column labels now with obligatory 'as'
> 
> > > Have just tried 9. Jan snapshot on AIX 4.1.5,
> > > compiles with gcc not with cc (fails in heaptuple.c), aix won't get
> > > defined though, did a -Daix
> >
> > IBM compiler doesn't like the (void)NULLs in the heap_getattr and
> > StrNCpy macros.  Change to (bool)NULL in heap_getattr in include/
> > access/heapam.h and to (char)NULL in StrNCpy in include/c.h. In 6.2,
> > heap_getattr has (char)NULL (which is what bool is, so this worked),
> > but gcc gave warnings, so they were changed to _errors_ to "fix" them
> > for 6.3.
> 
> Ack! It looks to me like the StrNCpy macro needs (void *)NULL or just
> NULL, not (void)NULL. Same with heap_getattr. Was this a workaround for
> a compiler problem on another platform, or are we mixing type coersions?

Prevented the warning 'right-hand side of conditional skipped...'  Try
and and see what you get.  It has to do with macro usage and constant
parameters.


-- 
Bruce Momjian
maillist@candle.pha.pa.us

Fri, 9 Jan 1998 15:10:11 -0500 (EST)
Bruce Momjian <maillist@candle.pha.pa.us>
Re: [HACKERS] column labels now with obligatory 'as'