6.2.3 Name spaces of identifiers

Previous Table of Contents "New C Standard" commentary

438 If more than one declaration of a particular identifier is visible at any point in a translation unit, the syntactic context disambiguates uses that refer to different entities.

439 Thus, there are separate name spaces for various categories of identifiers, as follows:

440 —  label names (disambiguated by the syntax of the label declaration and use);

441 —  the tags of structures, unions, and enumerations (disambiguated by following any24) of the keywords struct, union, or enum);

442 —  the members of structures or unions;

443 each structure or union has a separate name space for its members (disambiguated by the type of the expression used to access the member via the . or -> operator);

444 —  all other identifiers, called ordinary identifiers (declared in ordinary declarators or as enumeration constants).

445 Forward references: enumeration specifiers (, labeled statements (6.8.1), structure and union specifiers (, structure and union members (, tags (, the goto statement (

446 23) As specified in 6.2.1, the later declaration might hide the prior declaration.

447 24) There is only one name space for tags even though three are possible.


Created at: 2008-01-30 02:39:40 The text from WG14/N1256 is copyright © ISO