Re: MSVC compilers complain about snprintf

From: Andres Freund <andres(at)anarazel(dot)de>
To: Andrew Dunstan <andrew(dot)dunstan(at)2ndquadrant(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: MSVC compilers complain about snprintf
Date: 2018-10-17 21:31:31
Message-ID: 20181017213131.sytx4z6p6z5i2i3e@alap3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

On 2018-10-17 17:27:14 -0400, Andrew Dunstan wrote:
>
> The MSVC compilers are whingeing about recent changes in snprintf.c:
>
>
> src\port\snprintf.c(1051): warning C4146: unary minus operator
> applied to unsigned type, result still unsigned
>
>
> The line in question reads:
>
> uvalue = -(unsigned long long) value;

Yea, that's intended. Is there a way to silence that one, but just keep
the code largely similar?

Greetings,

Andres Freund

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2018-10-17 21:43:31 Re: Large writable variables
Previous Message Andrew Dunstan 2018-10-17 21:30:05 Re: pgsql: Add TAP tests for pg_verify_checksums