Re: pgsql: Fix for globals.c- c.h must come first

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Bruce Momjian <bruce(at)momjian(dot)us>, Stephen Frost <sfrost(at)snowman(dot)net>, pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: Re: pgsql: Fix for globals.c- c.h must come first
Date: 2018-06-19 19:21:04
Message-ID: 7842.1529436064@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Andres Freund <andres(at)anarazel(dot)de> writes:
> Are there arguments for doing this in postgres.h rather than c.h?

No, c.h is the correct place. The core problem is that we have to include
pg_config.h before <stdio.h> et al in order to have consistent libc APIs
(on platforms where this matters), and c.h is what does that.

> I think we shouldn't do this for v11, as it seems likely that some
> extensions would be broken. While not hard to fix, that seems
> unnecessary after beta1? Seems unlikely we'll introduce further cases
> before new features are merged.

Yeah, waiting for v12 seems fine.

regards, tom lane

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message Bruce Momjian 2018-06-19 19:54:01 pgsql: README: add URLs for openldap installation
Previous Message Andres Freund 2018-06-19 18:30:04 Re: pgsql: Fix for globals.c- c.h must come first