16 Library introduction [library]

16.3 Method of description [description]

16.3.3 Other conventions [conventions]

16.3.3.6 Freestanding items [freestanding.item]

A freestanding item is a declaration, entity, typedef-name, or macro that is required to be present in a freestanding implementation and a hosted implementation.
Unless otherwise specified, the requirements on freestanding items for a freestanding implementation are the same as the corresponding requirements for a hosted implementation, except that not all of the members of the namespaces are required to be present.
[Note 1: 
This implies that freestanding item enumerations have the same enumerators on freestanding implementations and hosted implementations.
Furthermore, class types have the same members and class templates have the same deduction guides on freestanding implementations and hosted implementations.
— end note]
A declaration in a header synopsis is a freestanding item if
  • it is followed by a comment that includes freestanding, or
  • the header synopsis begins with a comment that includes all freestanding.
An entity or typedef-name is a freestanding item if it is:
  • introduced by a declaration that is a freestanding item,
  • an enclosing namespace of a freestanding item,
  • a friend of a freestanding item,
  • denoted by a typedef-name that is a freestanding item, or
  • denoted by an alias template that is a freestanding item.
A macro is a freestanding item if it is defined in a header synopsis and
  • the definition is followed by a comment that includes freestanding, or
  • the header synopsis begins with a comment that includes all freestanding.
[Example 1: #define NULL see below // freestanding — end example]
[Example 2: // all freestanding namespace std { — end example]