Re: Further news on Clang - spurious warnings - Mailing list pgsql-hackers

From Heikki Linnakangas
Subject Re: Further news on Clang - spurious warnings
Date
Msg-id 4E3925AA.3050301@enterprisedb.com
Whole thread Raw
In response to Re: Further news on Clang - spurious warnings  (Peter Geoghegan <peter@2ndquadrant.com>)
Responses Re: Further news on Clang - spurious warnings
List pgsql-hackers
On 03.08.2011 13:05, Peter Geoghegan wrote:
> I don't believe that the standard allows for an implementation of
> enums as unsigned integers - after all, individual enum literals can
> be given corresponding negative integer values.

C99 says:

> Each enumerated type shall be compatible with char, a signed integer type, or an
> unsigned integer type. The choice of type is implementation-defined,110) but shall be
> capable of representing the values of all the members of the enumeration.

See also:

http://stackoverflow.com/questions/2579230/signedness-of-enum-in-c-c99-c-cx-gnu-c-gnu-c99

--   Heikki Linnakangas  EnterpriseDB   http://www.enterprisedb.com


pgsql-hackers by date:

Previous
From: Peter Geoghegan
Date:
Subject: Re: Further news on Clang - spurious warnings
Next
From: Peter Geoghegan
Date:
Subject: Re: Further news on Clang - spurious warnings