Re: Latest datetime changes produce gcc complaints

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Thomas Lockhart <lockhart(at)fourpalms(dot)org>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Latest datetime changes produce gcc complaints
Date: 2001-12-30 02:08:59
Message-ID: 200112300208.fBU28xg02678@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> make[3]: Entering directory `/home/postgres/pgsql/src/backend/parser'
> gcc -O1 -Wall -Wmissing-prototypes -Wmissing-declarations -g -I../../../src/include -c -o analyze.o analyze.c
> In file included from analyze.c:23:
> ../../../src/include/parser/parse.h:160: warning: `TIME' redefined
> ../../../src/include/utils/datetime.h:113: warning: this is the location of the previous definition
>
> and similarly in half a dozen other modules. This is very bad; I have
> no confidence that the correct value of the symbol is being used in each
> place that references it. Could we rename the one in datetime.h to a
> non-conflicting name?

Of course this brings up the question of whether there were any other
recent changes that will break ports. Thomas, can you check on that?
I didn't see your patch and can't find it in the archives. (Of course,
the fact the patch didn't compile and we are thinking of RC1 tomorrow
doesn't help.) :-)

OK, I see it now via CVS. There are almost 2k lines of code in the
patch. It looks like DATE and TIME are the only two new defines. Can
you change TIME to PGTIME and DATE to PGDATE? Seems safer.

Don't know about the rest of the code. Hope it works. :-)

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2001-12-30 02:13:36 Re: LWLock contention: I think I understand the problem
Previous Message Jeffrey W. Baker 2001-12-30 02:00:43 Re: LWLock contention: I think I understand the problem