From 458f88adfa2105c628e9075f9c31b144119fd447 Mon Sep 17 00:00:00 2001 From: Krystian Stasiowski Date: Wed, 25 Mar 2020 09:19:58 -0400 Subject: [PATCH 1/3] [dcl.stc] Define mutable subobject and make use of keyword consistent --- source/declarations.tex | 4 +++- source/expressions.tex | 2 +- source/templates.tex | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/source/declarations.tex b/source/declarations.tex index e1a73595c9..198b76cefd 100644 --- a/source/declarations.tex +++ b/source/declarations.tex @@ -482,6 +482,8 @@ The \tcode{mutable} specifier shall appear only in the declaration of a non-static data member\iref{class.mem} whose type is neither const-qualified nor a reference type. +A member subobject\iref{intro.object} corresponding to a non-static +data member declared with the \tcode{mutable} specifier is a \term{mutable subobject}. \begin{example} \begin{codeblock} class X { @@ -495,7 +497,7 @@ \begin{note} The \tcode{mutable} specifier on a class data member nullifies a \tcode{const} specifier applied to the containing class object and -permits modification of the mutable class member even though the rest of +permits modification of the \tcode{mutable} class member even though the rest of the object is const~(\ref{basic.type.qualifier}, \ref{dcl.type.cv}). \end{note} diff --git a/source/expressions.tex b/source/expressions.tex index ad63de88fa..3284a0aaae 100644 --- a/source/expressions.tex +++ b/source/expressions.tex @@ -6938,7 +6938,7 @@ \item an invocation of an implicitly-defined copy/move constructor or copy/move assignment operator -for a union whose active member (if any) is mutable, +for a union whose active member (if any) is \tcode{mutable}, unless the lifetime of the union object began within the evaluation of $E$; \item diff --git a/source/templates.tex b/source/templates.tex index 9b89dd4ed6..ce31567433 100644 --- a/source/templates.tex +++ b/source/templates.tex @@ -397,7 +397,7 @@ \item a literal class type with the following properties: \begin{itemize} \item -all base classes and non-static data members are public and non-mutable and +all base classes and non-static data members are public and no members are declared \tcode{mutable}, and \item the types of all bases classes and non-static data members are structural types or (possibly multi-dimensional) array thereof. From aa1e8a626c7683f19fdc70e72f502f7e380cdb8a Mon Sep 17 00:00:00 2001 From: Krystian Stasiowski Date: Wed, 25 Mar 2020 10:08:35 -0400 Subject: [PATCH 2/3] Change \tcode to \keyword --- source/declarations.tex | 8 ++++---- source/expressions.tex | 2 +- source/templates.tex | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/source/declarations.tex b/source/declarations.tex index 198b76cefd..8f807a237e 100644 --- a/source/declarations.tex +++ b/source/declarations.tex @@ -479,11 +479,11 @@ \end{example} \pnum -The \tcode{mutable} specifier shall appear only in the declaration of +The \keyword{mutable} specifier shall appear only in the declaration of a non-static data member\iref{class.mem} whose type is neither const-qualified nor a reference type. A member subobject\iref{intro.object} corresponding to a non-static -data member declared with the \tcode{mutable} specifier is a \term{mutable subobject}. +data member declared with the \keyword{mutable} specifier is a \term{mutable subobject}. \begin{example} \begin{codeblock} class X { @@ -495,9 +495,9 @@ \pnum \begin{note} -The \tcode{mutable} specifier on a class data member nullifies a +The \keyword{mutable} specifier on a class data member nullifies a \tcode{const} specifier applied to the containing class object and -permits modification of the \tcode{mutable} class member even though the rest of +permits modification of the \keyword{mutable} class member even though the rest of the object is const~(\ref{basic.type.qualifier}, \ref{dcl.type.cv}). \end{note} diff --git a/source/expressions.tex b/source/expressions.tex index 3284a0aaae..2484bca7e1 100644 --- a/source/expressions.tex +++ b/source/expressions.tex @@ -6938,7 +6938,7 @@ \item an invocation of an implicitly-defined copy/move constructor or copy/move assignment operator -for a union whose active member (if any) is \tcode{mutable}, +for a union whose active member (if any) is \keyword{mutable}, unless the lifetime of the union object began within the evaluation of $E$; \item diff --git a/source/templates.tex b/source/templates.tex index ce31567433..4f38978f0d 100644 --- a/source/templates.tex +++ b/source/templates.tex @@ -397,7 +397,7 @@ \item a literal class type with the following properties: \begin{itemize} \item -all base classes and non-static data members are public and no members are declared \tcode{mutable}, and +all base classes and non-static data members are public and no members are declared \keyword{mutable}, and \item the types of all bases classes and non-static data members are structural types or (possibly multi-dimensional) array thereof. From 86fa66dce86bdf799f8c4644e8804b5736161dd0 Mon Sep 17 00:00:00 2001 From: Krystian Stasiowski Date: Wed, 25 Mar 2020 17:20:08 -0400 Subject: [PATCH 3/3] Change \term to \defnadj --- source/declarations.tex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/declarations.tex b/source/declarations.tex index 8f807a237e..211c584f4c 100644 --- a/source/declarations.tex +++ b/source/declarations.tex @@ -483,7 +483,7 @@ a non-static data member\iref{class.mem} whose type is neither const-qualified nor a reference type. A member subobject\iref{intro.object} corresponding to a non-static -data member declared with the \keyword{mutable} specifier is a \term{mutable subobject}. +data member declared with the \keyword{mutable} specifier is a \defnadj{mutable}{subobject}. \begin{example} \begin{codeblock} class X {