|
3914 | 3914 | \term{volatile-qualified} version, and a |
3915 | 3915 | \term{const-volatile-qualified} version. The term |
3916 | 3916 | \term{object type}~(\ref{intro.object}) includes the cv-qualifiers |
3917 | | -specified when the object is created. The presence of a \tcode{const} |
3918 | | -specifier in a \grammarterm{decl-specifier-seq} declares an object of |
3919 | | -\term{const-qualified object type}; such |
3920 | | -object is called a \term{const object}. The presence of a |
3921 | | -\tcode{volatile} specifier in a \grammarterm{decl-specifier-seq} declares |
3922 | | -an object of \grammarterm{volatile-qualified} \term{object type}; such object |
3923 | | -is called a \term{volatile object}. The presence of both \grammarterm{cv-qualifiers} in a |
3924 | | -\grammarterm{decl-specifier-seq} declares an object of |
3925 | | -\term{const-volatile-qualified object type}; |
3926 | | -such object is called a \term{const volatile object}. The cv-qualified or |
| 3917 | +specified in the \grammarterm{decl-specifier-seq}~(\ref{dcl.spec}), |
| 3918 | +\grammarterm{declarator} (Clause~\ref{dcl.decl}), |
| 3919 | +\grammarterm{type-id}~(\ref{dcl.name}), or |
| 3920 | +\grammarterm{new-type-id}~(\ref{expr.new}) when the object is created. |
| 3921 | + |
| 3922 | +\begin{itemize} |
| 3923 | +\item A \term{const object} is an object of type \tcode{const T} or a |
| 3924 | + non-mutable subobject of such an object. |
| 3925 | + |
| 3926 | +\item A \term{volatile object} is an object of type |
| 3927 | + \tcode{volatile T}, a subobject of such an object, or a mutable |
| 3928 | + subobject of a const volatile object. |
| 3929 | + |
| 3930 | +\item A \term{const volatile object} is an object of type |
| 3931 | + \tcode{const volatile T}, a non-mutable subobject of such an object, |
| 3932 | + a const subobject of a volatile object, or a non-mutable volatile |
| 3933 | + subobject of a const object. |
| 3934 | + |
| 3935 | +\end{itemize} |
| 3936 | + |
| 3937 | +The cv-qualified or |
3927 | 3938 | cv-unqualified versions of a type |
3928 | 3939 | are distinct types; however, they shall have the same representation and |
3929 | 3940 | alignment requirements~(\ref{basic.align}).\footnote{The same representation |
|
3939 | 3950 | not the array type~(\ref{dcl.array}). |
3940 | 3951 |
|
3941 | 3952 | \pnum |
3942 | | -\indextext{class~object!\idxcode{const}}% |
3943 | | -Each non-static, non-mutable, non-reference data member of a |
3944 | | -const-qualified class object is const-qual\-i\-fied, each non-static, |
3945 | | -non-reference data member of a volatile-qualified class object is |
3946 | | -volatile-qualified and similarly for members of a const-volatile class. |
3947 | 3953 | See~\ref{dcl.fct} and~\ref{class.this} regarding function |
3948 | 3954 | types that have \grammarterm{cv-qualifier}{s}. |
3949 | 3955 |
|
|
0 commit comments