Re: ECPG SQLDA support

Boszormenyi Zoltan <zb@cybertec.at>

From: Boszormenyi Zoltan <zb@cybertec.at>
To: Alvaro Herrera <alvherre@commandprompt.com>
Cc: Michael Meskes <meskes@postgresql.org>, pgsql-hackers@postgresql.org, Hans-Juergen Schoenig <hs@cybertec.at>
Date: 2010-01-04T19:13:52Z
Lists: pgsql-hackers
Alvaro Herrera írta:
> Boszormenyi Zoltan wrote:
>
> I happened to notice this by chance:
>
>   
>> + #if (LONG_BIT == 64)
>> + #define	SQLINT8		ECPGt_long
>> + #define	SQLSERIAL8	ECPGt_long
>> + #else
>> + #define	SQLINT8		ECPGt_long_long
>> + #define	SQLSERIAL8	ECPGt_long_long
>> + #endif
>>     
>
> I'm not sure how portable is the LONG_BIT business.  We don't seem to
> use it anywhere else (hmm, but then we do use CHAR_BIT elsewhere)
>   

I specifically looked for a portable solution, as
    #if sizeof(...) == N
is not evaluated at compile time.

Best regards,
Zoltán Böszörményi

-- 
Bible has answers for everything. Proof:
"But let your communication be, Yea, yea; Nay, nay: for whatsoever is more
than these cometh of evil." (Matthew 5:37) - basics of digital technology.
"May your kingdom come" - superficial description of plate tectonics

----------------------------------
Zoltán Böszörményi
Cybertec Schönig & Schönig GmbH
http://www.postgresql.at/