The optional member-list is a sequence including, but not exclusive to:
- Data declarations (of any type, including enumerations, bit fields and other classes)
- Nested type declarations
- Nested type definitions
- Template declarations
- Template definitions
- Function declarations
- Function definitions
- Constructors
- A destructor
Members of a class can optional have storage class specifiers and access modifiers. The objects thus defined are called class members. The storage class specifiers
auto,
extern, and
register are not allowed. Members can be declared with the
static storage class specifiers.