Re: Question about ECPGset_noind_null() and ECPGis_noind_null()

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Boszormenyi Zoltan <zb(at)cybertec(dot)at>, Michael Meskes <meskes(at)postgresql(dot)org>, pgsql-hackers(at)postgresql(dot)org, Hans-Juergen Schoenig <hs(at)cybertec(dot)at>
Subject: Re: Question about ECPGset_noind_null() and ECPGis_noind_null()
Date: 2009-11-19 19:46:50
Message-ID: 4B05A0AA.7050503@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:
> Boszormenyi Zoltan <zb(at)cybertec(dot)at> writes:
>
>> for (; length > 0 && ptr[--length] == 0xff;);
>>
>
>
>> I suspect that GCC does the "--length" after checking
>> "length > 0" and before checking the "ptr[...] == 0xff",
>> but HP CC does it before checking "length > 0".
>>
>
> If it does, that is *unquestionably* a bug in HP's CC and should be
> reported to them.
>

Wow, I recall fighting HP over a bad compiler bug (although not as bad
as this would be) 15 years ago. Their official response amounted to "we
don't care and we're not going to fix it". Maybe not much has changed.

cheers

andrew

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message James Pye 2009-11-19 20:12:34 Re: Python 3.1 support
Previous Message Tom Lane 2009-11-19 19:33:47 Re: Question about ECPGset_noind_null() and ECPGis_noind_null()