Re: bool: symbol name collision - Mailing list pgsql-bugs

From bryanh@giraffe-data.com (Bryan Henderson)
Subject Re: bool: symbol name collision
Date
Msg-id 96067.bryanh@giraffe-data.com
Whole thread Raw
In response to Re: bool: symbol name collision  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-bugs
>On the flip side if the code that purports to cope with other
>definitions of bool is useless, we should remove it so as to avoid
>giving the impression that we have any ability to so cope.

Indeed, that code is what led me to believe I could work around my bool
conflict problem with a "#define bool bool" in my code.  It appeared to work
at first -- the code compiled and even ran, but later when I added a Version 1
function (that's an interface that has a structure with a "bool" member),
things fell apart (my compiler's bool is 4 bytes) and it took hours to trace
it back to my workaround and try something else.

So it would be an improvement to remove the code that purports to cope with
other definitions of bool.  And maybe add a comment emphasizing that "bool" is
part of the binary interface between server extensions and the base server.

--
Bryan Henderson                                   San Jose, California

pgsql-bugs by date:

Previous
From: "Mason Hale"
Date:
Subject: BUG #5459: Unable to cancel query while in send()
Next
From: Tom Lane
Date:
Subject: Re: BUG #5459: Unable to cancel query while in send()