Re: [HACKERS] [COMMITTERS] pgsql: Fix compiler warnings on 64-bit boxes:

2006-09-06 Thread Tom Lane
Teodor Sigaev <[EMAIL PROTECTED]> writes: >> ereport(...errmsg("trouble at offset " UINT64_FORMAT, bigintvar)); > One more solution: add format code %D to expand_fmt_string() which should be > expanded to usual %d on 32-bit architecture and to UINT64_FORMAT on 64-bit. Not very workable unless yo

Re: [HACKERS] [COMMITTERS] pgsql: Fix compiler warnings on 64-bit

2006-09-06 Thread Teodor Sigaev
ereport(...errmsg("trouble at offset " UINT64_FORMAT, bigintvar)); One more solution: add format code %D to expand_fmt_string() which should be expanded to usual %d on 32-bit architecture and to UINT64_FORMAT on 64-bit. -- Teodor Sigaev E-mail: [EMAIL

Re: [HACKERS] [COMMITTERS] pgsql: Fix compiler warnings on 64-bit boxes:

2006-09-06 Thread Tom Lane
Gavin Sherry <[EMAIL PROTECTED]> writes: > It might seem a minor quibble, but it seems like a more reliable approach > might be to cast to a 64 bit type and user a 64 bit int formatter. int64 is a real pain to use in error messages because of the machine-dependence of the format string --- the tra