#3931 closed defect (fixed)

PG11: Remove TRUE and FALSE

Reported by: Algunenano Owned by: pramsey
Priority: high Milestone: PostGIS 2.5.0
Component: postgis Version: trunk
Keywords: Cc:


PostgreSQL has removed TRUE and FALSE from c.h keeping only true and false:

From http://www.postgresql-archive.org/PostgreSQL-Weekly-News-November-19-2017-td5992809.html

- Remove TRUE and FALSE.  Code should be using true and false.  Existing code 
  can be changed to those in a backward compatible way.  The definitions in the 
  ecpg header files are left around to avoid upsetting those users 
  unnecessarily.  Reviewed-by: Michael Paquier <[hidden email]> 

This breaks PostGIS compilation in several places, for example:

lwgeom_transform.c:170:9: error: ‘FALSE’ undeclared (first use in this function); did you mean ‘FILE’?
  return FALSE;

Github's PR: https://github.com/postgis/postgis/pull/172 I've checked PostgreSQL 9.2 headers and true was already available, so changing TRUE for true should be safe.

Change History (1)

comment:1 Changed 20 months ago by pramsey

Resolution: fixed
Status: newclosed

In 16116:

PgSQL 11 support, change from FALSE to false, etc.
Closes #3931, from Raúl Marín Rodríguez

Note: See TracTickets for help on using tickets.