On 08/24/2017 02:25 PM, Dale Noble wrote:
Dear GNU Reference https://www.gnu.org/software/gnu-c-manual/gnu-c-manual.html Section 2.2.1 and 2.2.2 on enumerations. I do not think that these are correct. To define something causes storage allocation (its creation). To declare something does not causes storage allocation (no creation). Looks like 2.2.1 and 2.2.2 are switched.
I don't think they're switched but I do agree that the terminology used there isn't entirely accurate. An enumeration in the C and C++ standards means the set of named constants defined by an enumerated type (called enumeration constants). So the title of 2.2.1 is correct. But the title of 2.2.2 is not really correct because the section talks about declaring variables of enumerated types, not the types themselves. The title would be more accurate if it were changed to something like "Declaring Enumerated Variables." Martin