C99 types patch

Barry Scott barry.scott at onelan.co.uk
Tue Oct 27 09:08:31 PDT 2009

Mark Kettenis wrote:
>> Date: Wed, 21 Oct 2009 23:56:46 -0400
>> From: Eamon Walsh <ewalsh at tycho.nsa.gov>
>>>> I would love love love to see us move entirely to stdint types instead
>>>> of the mess we've got now.
>>> Yes. Yes yes yes.
>> I have a patch sitting around that does this, guess I'll float it.
> Hmm, isn't this going to weak havoc for C++? If I read your diff
> correctly, it'll change from
> typedef unsigned long XID;
> into what's effectively
> typedef uint32_t XID;
> on 32-bit systems.
> Now if your system defines uint32_t as:
> typedef unsigned int uint32_t;
> this will change how C++ functions that take an XID as one of its
> arguments are magled, causing major ABI breakage.
Isn't this solved in the traditional way by adding:

#ifdef __cplusplus
extern "C" {
#ifdef __cplusplus


p.s. (second send to get all)

More information about the xorg-devel mailing list