Re: VS 2015 support in src/tools/msvc - Mailing list pgsql-hackers

From Tom Lane
Subject Re: VS 2015 support in src/tools/msvc
Date
Msg-id 17239.1461448469@sss.pgh.pa.us
Whole thread Raw
In response to Re: VS 2015 support in src/tools/msvc  (Andrew Dunstan <andrew@dunslane.net>)
Responses Re: VS 2015 support in src/tools/msvc  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Andrew Dunstan <andrew@dunslane.net> writes:
> On 04/23/2016 05:30 PM, Christian Ullrich wrote:
>> In this case, I would prefer this:
>>
>> #ifdef WIN32_ONLY_COMPILER
>> -typedef int pid_t;
>> +typedef intptr_t pid_t;
>> #endif

> That's a change that will have a pretty wide effect. Everything up to 
> now has been pretty low risk, but this worries me rather more. Maybe 
> it's safe, but I'd like to hear others' comments.

Yeah, it makes me a bit nervous too.  We know that most of the code is
agnostic as to the width of pid_t, because it works on Unixen where
pid_t is 64bit.  But I'm less sure about whether the Windows-specific
parts are equally flexible.

On the other hand, wouldn't you expect to get compiler warnings for
any code that does get affected?  The main hazard would be incorrect
printf format flags (cf 994f11257 for a recent example), and I'd
certainly expect any C compiler worth its salt to whine about
inconsistencies there.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: VS 2015 support in src/tools/msvc
Next
From: Tom Lane
Date:
Subject: Re: VS 2015 support in src/tools/msvc