The members of a standard module consist of the members introduced by its member declarations and the members inherited from Object
. Standard modules may have any type of member except instance constructors. All standard module type members are implicitly shared.
A standard module member declaration may have public, friend, or private access. When a standard module member declaration does not include an access modifier, the declaration defaults to public access, unless it is a data member, which defaults to private access. As previously noted, the scope of a standard module member is the declaration containing the standard module declaration. Members inherited from Object
are not included in this special scoping; those members have no scope and must always be qualified with the name of the module. If the member has friend access, its scope extends only to namespace members declared in the same program.