Re: BUG #13689: Build failed pg9.4.5 with mingw5.1 - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #13689: Build failed pg9.4.5 with mingw5.1
Date
Msg-id 33045.1445357220@sss.pgh.pa.us
Whole thread Raw
In response to Re: BUG #13689: Build failed pg9.4.5 with mingw5.1  (Bruce Momjian <bruce@momjian.us>)
Responses Re: BUG #13689: Build failed pg9.4.5 with mingw5.1  (kang joni <kangjoni76@gmail.com>)
List pgsql-bugs
Bruce Momjian <bruce@momjian.us> writes:
> On Tue, Oct 20, 2015 at 04:37:37AM +0000, kangjoni76@gmail.com wrote:
>> Invalid conversion ForkNumber to int...
>> error build failed ForkNumber type doesn't have operator++.
>> This happen in src/common/relpath.c:52 and also at line 86.

> Wow, we are incrementing an enum here.  Is that legal?  What compiler
> are you using?

Possibly C++ doesn't allow that?  But if so, it's user error.
Postgres is written in C not C++.

(I could see a compiler issuing a warning here that forkNum will
get incremented past the declared range of the enum.  But that
doesn't seem to be what's being reported.)

            regards, tom lane

pgsql-bugs by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: BUG #13689: Build failed pg9.4.5 with mingw5.1
Next
From: Tom Lane
Date:
Subject: Re: BUG #13690: Full Text Search with spanish dictionary cannot find some words