Re: bool: symbol name collision

From: bryanh(at)giraffe-data(dot)com (Bryan Henderson)
To: robertmhaas(at)gmail(dot)com
Cc: peter_e(at)gmx(dot)net, tgl(at)sss(dot)pgh(dot)pa(dot)us, pgsql-bugs(at)postgresql(dot)org
Subject: Re: bool: symbol name collision
Date: 2010-05-11 21:12:27
Message-ID: 96067.bryanh@giraffe-data.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: 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

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Mason Hale 2010-05-11 21:29:06 BUG #5459: Unable to cancel query while in send()
Previous Message Peter Eisentraut 2010-05-11 20:15:17 Re: bool: symbol name collision