Opened 7 years ago

Closed 7 years ago

#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: master
Keywords: Cc:

Description

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]> 
  https://git.postgresql.org/pg/commitdiff/6337865f36da34e9c89aaa292f976bde6df0b065

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;
         ^~~~~
         FILE

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 by pramsey, 7 years ago

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.