diff --git a/source/atomics.tex b/source/atomics.tex index b80acf29a9..a68674b232 100644 --- a/source/atomics.tex +++ b/source/atomics.tex @@ -1918,7 +1918,7 @@ \begin{note} For example, the effect of \tcode{compare_exchange_strong} -on objects without padding bits\iref{basic.types} is +on objects without padding bits\iref{term.padding.bits} is \begin{codeblock} if (memcmp(this, &expected, sizeof(*this)) == 0) memcpy(this, &desired, sizeof(*this)); diff --git a/source/basic.tex b/source/basic.tex index 08f66e09a5..b32f487d25 100644 --- a/source/basic.tex +++ b/source/basic.tex @@ -318,7 +318,7 @@ \indextext{type!incomplete}% In the definition of an object, the type of that object shall not be -an incomplete type\iref{basic.types.general}, +an incomplete type\iref{term.incomplete.type}, an abstract class type\iref{class.abstract}, or a (possibly multi-dimensional) array thereof. @@ -4595,6 +4595,7 @@ \indextext{object!byte copying and|)} \pnum +\label{term.object.representation}% The \defnx{object representation}{representation!object} of an object of type \tcode{T} is the sequence of \placeholder{N} \tcode{\keyword{unsigned} \keyword{char}} objects taken up @@ -4603,6 +4604,7 @@ The \defnx{value representation}{representation!value} of an object of type \tcode{T} is the set of bits that participate in representing a value of type \tcode{T}. +\label{term.padding.bits}% Bits in the object representation that are not part of the value representation are \defn{padding bits}. For trivially copyable types, the value representation is @@ -4625,8 +4627,9 @@ The size and layout of an instance of an incompletely-defined object type is unknown. \end{footnote} +\label{term.incomplete.type}% Incompletely-defined object types and \cv{}~\keyword{void} are -\defnx{incomplete types}{type!incomplete}\iref{basic.fundamental}. +\defnadjx{incomplete}{types}{type}\iref{basic.fundamental}. \begin{note} Objects cannot be defined to have an incomplete type\iref{basic.def}. \end{note} @@ -4681,6 +4684,7 @@ \end{note} \pnum +\label{term.object.type}% An \defn{object type} is a (possibly cv-qualified) type that is not a function type, not a reference type, and not \cv{}~\keyword{void}. @@ -4688,6 +4692,7 @@ \indextext{class!trivial}% \indextext{class!trivially copyable}% \indextext{class!standard-layout}% +\label{term.scalar.type}% Arithmetic types\iref{basic.fundamental}, enumeration types, pointer types, pointer-to-member types\iref{basic.compound}, \tcode{std::nullptr_t}, @@ -4695,13 +4700,17 @@ cv-qualified\iref{basic.type.qualifier} versions of these types are collectively called \defnadjx{scalar}{types}{type}. +\label{term.trivially.copyable.type}% Scalar types, trivially copyable class types\iref{class.prop}, arrays of such types, and cv-qualified versions of these types are collectively called \defnadjx{trivially copyable}{types}{type}. +\label{term.trivial.type}% Scalar types, trivial class types\iref{class.prop}, arrays of such types and cv-qualified versions of these types are collectively called -\defnadjx{trivial}{types}{type}. Scalar types, standard-layout class +\defnadjx{trivial}{types}{type}. +\label{term.standard.layout.type}% +Scalar types, standard-layout class types\iref{class.prop}, arrays of such types and cv-qualified versions of these types are collectively called \defnadjx{standard-layout}{types}{type}. @@ -4710,6 +4719,7 @@ are collectively called \defnadjx{implicit-lifetime}{types}{type}. \pnum +\label{term.literal.type}% A type is a \defnadj{literal}{type} if it is: \begin{itemize} \item \cv{}~\keyword{void}; or @@ -4741,9 +4751,9 @@ \end{note} \pnum -\indextext{layout-compatible type}% +\label{term.layout.compatible.type}% Two types \cvqual{cv1} \tcode{T1} and \cvqual{cv2} \tcode{T2} are -\defn{layout-compatible} types +\defnadjx{layout-compatible}{types}{type} if \tcode{T1} and \tcode{T2} are the same type, layout-compatible enumerations\iref{dcl.enum}, or layout-compatible standard-layout class types\iref{class.mem}. diff --git a/source/classes.tex b/source/classes.tex index c2fac93429..bba2a790c8 100644 --- a/source/classes.tex +++ b/source/classes.tex @@ -602,7 +602,7 @@ \pnum A class is considered a completely-defined object -type\iref{basic.types} (or complete type) at the closing \tcode{\}} of +type\iref{term.incomplete.type} (or complete type) at the closing \tcode{\}} of the \grammarterm{class-specifier}. The class is regarded as complete within its complete-class contexts; otherwise it is regarded as incomplete within its own class @@ -689,7 +689,7 @@ \pnum \indextext{class object!member}% The type of a non-static data member shall not be an -incomplete type\iref{basic.types}, +incomplete type\iref{term.incomplete.type}, an abstract class type\iref{class.abstract}, or a (possibly multi-dimensional) array thereof. \begin{note} @@ -812,7 +812,7 @@ Two standard-layout unions are layout-compatible if they have the same number of non-static data members and corresponding non-static data members (in any order) have layout-compatible -types\iref{basic.types}. +types\iref{term.layout.compatible.type}. \pnum In a standard-layout union with an active member\iref{class.union} @@ -1659,7 +1659,7 @@ \pnum The implicitly-defined copy/move constructor for a union -\tcode{X} copies the object representation\iref{basic.types} of \tcode{X}. +\tcode{X} copies the object representation\iref{term.object.representation} of \tcode{X}. For each object nested within\iref{intro.object} the object that is the source of the copy, a corresponding object $o$ nested within the destination @@ -1984,7 +1984,7 @@ \pnum The implicitly-defined copy assignment operator for a -union \tcode{X} copies the object representation\iref{basic.types} of \tcode{X}. +union \tcode{X} copies the object representation\iref{term.object.representation} of \tcode{X}. If the source and destination of the assignment are not the same object, then for each object nested within\iref{intro.object} the object that is the source of the copy, @@ -2823,7 +2823,7 @@ If the width of a bit-field is larger than the width of the bit-field's type (or, in case of an enumeration type, of its underlying type), -the extra bits are padding bits\iref{basic.types}. +the extra bits are padding bits\iref{term.padding.bits}. \indextext{allocation!implementation-defined bit-field}% Allocation of bit-fields within a class object is \impldef{allocation of bit-fields within a class object}. diff --git a/source/concepts.tex b/source/concepts.tex index 1359fb4608..439f541970 100644 --- a/source/concepts.tex +++ b/source/concepts.tex @@ -637,7 +637,7 @@ \tcode{S} is an expression that exchanges the denoted values. \tcode{S} is a constant expression if \begin{itemize} - \item \tcode{T} is a literal type\iref{basic.types}, + \item \tcode{T} is a literal type\iref{term.literal.type}, \item both \tcode{E1 = std::move(E2)} and \tcode{E2 = std::move(E1)} are constant subexpressions\iref{defns.const.subexpr}, and \item the full-expressions of the initializers in the declarations diff --git a/source/containers.tex b/source/containers.tex index f9ab3e8128..f80b1e64a8 100644 --- a/source/containers.tex +++ b/source/containers.tex @@ -14429,7 +14429,8 @@ \end{codeblock} \pnum -\tcode{span} is a trivially copyable type\iref{basic.types.general}. +\tcode{span} is +a trivially copyable type\iref{term.trivially.copyable.type}. \pnum \tcode{ElementType} is required to be diff --git a/source/declarations.tex b/source/declarations.tex index 5697f1c628..badf50f8e9 100644 --- a/source/declarations.tex +++ b/source/declarations.tex @@ -4367,7 +4367,7 @@ \item if \tcode{T} -is a scalar type\iref{basic.types}, the +is a scalar type\iref{term.scalar.type}, the object is initialized to the value obtained by converting the integer literal \tcode{0} (zero) to @@ -4383,7 +4383,7 @@ if \tcode{T} is a (possibly cv-qualified) non-union class type, -its padding bits\iref{basic.types} are initialized to zero bits and +its padding bits\iref{term.padding.bits} are initialized to zero bits and each non-static data member, each non-virtual base class subobject, and, if the object is not a base class subobject, @@ -4394,7 +4394,7 @@ if \tcode{T} is a (possibly cv-qualified) union type, -its padding bits\iref{basic.types} are initialized to zero bits and +its padding bits\iref{term.padding.bits} are initialized to zero bits and the object's first non-static named data member diff --git a/source/expressions.tex b/source/expressions.tex index 1b77ea9519..08d450de78 100644 --- a/source/expressions.tex +++ b/source/expressions.tex @@ -2863,7 +2863,7 @@ \pnum A \grammarterm{type-requirement} that names a class template specialization -does not require that type to be complete\iref{basic.types}. +does not require that type to be complete\iref{term.incomplete.type}. \rSec3[expr.prim.req.compound]{Compound requirements} \indextext{requirement!compound}% @@ -4826,7 +4826,7 @@ \end{note} \begin{note} See~\ref{intro.memory} for the definition of byte -and~\ref{basic.types} for the definition of object representation. +and~\ref{term.object.representation} for the definition of object representation. \end{note} \pnum @@ -4952,9 +4952,9 @@ \grammarterm{type-id}\iref{dcl.name} or \grammarterm{new-type-id} to which it is applied. The type of that object is the \defnadj{allocated}{type}. \indextext{type!incomplete}% -This type shall be a complete object type, but not an abstract class -type or array -thereof~(\ref{intro.object}, \ref{basic.types}, \ref{class.abstract}). +This type shall be a complete object type\iref{term.incomplete.type}, +but not an abstract class type\iref{class.abstract} or array +thereof\iref{intro.object}. \begin{note} Because references are not objects, references cannot be created by \grammarterm{new-expression}{s}. diff --git a/source/lib-intro.tex b/source/lib-intro.tex index e772f8b038..0685cc3c32 100644 --- a/source/lib-intro.tex +++ b/source/lib-intro.tex @@ -1836,7 +1836,7 @@ {allocator.req.var} \topline \lhdr{Variable} & \rhdr{Definition} \\ \capsep -\tcode{T, U, C} & any \cv-unqualified object type\iref{basic.types} \\ \rowsep +\tcode{T, U, C} & any \cv-unqualified object type\iref{term.object.type} \\ \rowsep \tcode{X} & an allocator class for type \tcode{T} \\ \rowsep \tcode{Y} & the corresponding allocator class for type \tcode{U} \\ \rowsep \tcode{XX} & the type \tcode{allocator_traits} \\ \rowsep @@ -2807,7 +2807,7 @@ \required paragraph. \item -If an incomplete type\iref{basic.types} is used as a template +If an incomplete type\iref{term.incomplete.type} is used as a template argument when instantiating a template component or evaluating a concept, unless specifically allowed for that component. \end{itemize} diff --git a/source/numerics.tex b/source/numerics.tex index 7a2adb52c4..735d2a3238 100644 --- a/source/numerics.tex +++ b/source/numerics.tex @@ -197,7 +197,7 @@ The specializations \tcode{complex}, \tcode{complex}, and -\tcode{complex} are literal types\iref{basic.types}. +\tcode{complex} are literal types\iref{term.literal.type}. \pnum If the result of a function is not mathematically defined or not in diff --git a/source/strings.tex b/source/strings.tex index 67d7f43579..783a688896 100644 --- a/source/strings.tex +++ b/source/strings.tex @@ -5,7 +5,7 @@ \pnum This Clause describes components for manipulating sequences of -any non-array trivial standard-layout\iref{basic.types} type. +any non-array trivial standard-layout\iref{term.standard.layout.type} type. Such types are called \defnx{char-like types}{char-like type}, and objects of char-like types are called \defnx{char-like objects}{char-like object} or @@ -4368,7 +4368,8 @@ unless otherwise specified. \pnum -\tcode{basic_string_view} is a trivially copyable type\iref{basic.types.general}. +\tcode{basic_string_view} is +a trivially copyable type\iref{term.trivially.copyable.type}. \rSec3[string.view.cons]{Construction and assignment} diff --git a/source/templates.tex b/source/templates.tex index 5c3b07c319..a831fc7687 100644 --- a/source/templates.tex +++ b/source/templates.tex @@ -1157,7 +1157,7 @@ \end{codeblock} \end{example} \begin{note} -A template type argument can be an incomplete type\iref{basic.types}. +A template type argument can be an incomplete type\iref{term.incomplete.type}. \end{note} \rSec2[temp.arg.nontype]{Template non-type arguments} @@ -5724,7 +5724,7 @@ If the template selected for the specialization\iref{temp.spec.partial.match} has been declared, but not defined, at the point of instantiation\iref{temp.point}, -the instantiation yields an incomplete class type\iref{basic.types}. +the instantiation yields an incomplete class type\iref{term.incomplete.type}. \begin{example} \begin{codeblock} template class X; diff --git a/source/utilities.tex b/source/utilities.tex index 1e5903d28b..992a68b2c1 100644 --- a/source/utilities.tex +++ b/source/utilities.tex @@ -8764,7 +8764,7 @@ Initializes the first \tcode{M} bit positions to the corresponding bit values in \tcode{val}. \tcode{M} is the smaller of \tcode{N} and the number of bits in the value -representation\iref{basic.types} of \tcode{unsigned long long}. +representation\iref{term.object.representation} of \tcode{unsigned long long}. If \tcode{M < N}, the remaining bit positions are initialized to zero. \end{itemdescr} @@ -10917,7 +10917,7 @@ \begin{itemdescr} \pnum \mandates -\tcode{T} is not an incomplete type\iref{basic.types}. +\tcode{T} is not an incomplete type\iref{term.incomplete.type}. \pnum \returns @@ -10947,7 +10947,7 @@ \begin{itemdescr} \pnum \mandates -\tcode{T} is not an incomplete type\iref{basic.types}. +\tcode{T} is not an incomplete type\iref{term.incomplete.type}. \pnum \returns @@ -16160,7 +16160,7 @@ \pnum A \defnx{function object type}{function object!type} is an object -type\iref{basic.types} that can be the type of the +type\iref{term.object.type} that can be the type of the \grammarterm{postfix-expression} in a function call (\ref{expr.call}, \ref{over.match.call}). \begin{footnote} @@ -16581,7 +16581,8 @@ around a reference to an object or function of type \tcode{T}. \pnum -\tcode{reference_wrapper} is a trivially copyable type\iref{basic.types}. +\tcode{reference_wrapper} is +a trivially copyable type\iref{term.trivially.copyable.type}. \pnum The template parameter \tcode{T} of \tcode{reference_wrapper} @@ -20109,11 +20110,11 @@ \indexlibraryglobal{is_object}% \tcode{template}\br \tcode{struct is_object;} & - \tcode{T} is an object type\iref{basic.types} & \\ \rowsep + \tcode{T} is an object type\iref{term.object.type} & \\ \rowsep \indexlibraryglobal{is_scalar}% \tcode{template}\br \tcode{struct is_scalar;} & - \tcode{T} is a scalar type\iref{basic.types} & \\ \rowsep + \tcode{T} is a scalar type\iref{term.scalar.type} & \\ \rowsep \indexlibraryglobal{is_compound}% \tcode{template}\br \tcode{struct is_compound;} & @@ -20144,7 +20145,7 @@ \pnum For the purpose of defining the templates in this subclause, a function call expression \tcode{declval()} for any type \tcode{T} -is considered to be a trivial~(\ref{basic.types}, \ref{special}) function call +is considered to be a trivial~(\ref{term.trivial.type}, \ref{special}) function call that is not an odr-use\iref{term.odr.use} of \tcode{declval} in the context of the corresponding definition notwithstanding the restrictions of~\ref{declval}. @@ -20190,21 +20191,21 @@ \indexlibraryglobal{is_trivial}% \tcode{template}\br \tcode{struct is_trivial;} & - \tcode{T} is a trivial type\iref{basic.types} & + \tcode{T} is a trivial type\iref{term.trivial.type} & \tcode{remove_all_extents_t} shall be a complete type or \cv{}~\keyword{void}. \\ \rowsep \indexlibraryglobal{is_trivially_copyable}% \tcode{template}\br \tcode{struct is_trivially_copyable;} & - \tcode{T} is a trivially copyable type\iref{basic.types} & + \tcode{T} is a trivially copyable type\iref{term.trivially.copyable.type} & \tcode{remove_all_extents_t} shall be a complete type or \cv{}~\keyword{void}. \\ \rowsep \indexlibraryglobal{is_standard_layout}% \tcode{template}\br \tcode{struct is_standard_layout;} & - \tcode{T} is a standard-layout type\iref{basic.types} & + \tcode{T} is a standard-layout type\iref{term.standard.layout.type} & \tcode{remove_all_extents_t} shall be a complete type or \cv{}~\keyword{void}. \\ \rowsep @@ -20404,7 +20405,7 @@ \tcode{is_constructible_v} is \tcode{true} and the variable definition for \tcode{is_constructible}, as defined below, is known to call - no operation that is not trivial~(\ref{basic.types}, \ref{special}). & + no operation that is not trivial~(\ref{term.trivial.type}, \ref{special}). & \tcode{T} and all types in the template parameter pack \tcode{Args} shall be complete types, \cv{}~\keyword{void}, or arrays of unknown bound. \\ \rowsep @@ -20439,7 +20440,7 @@ \tcode{struct is_trivially_assignable;} & \tcode{is_assignable_v} is \tcode{true} and the assignment, as defined by \tcode{is_assignable}, is known to call no operation that is not trivial - ~(\ref{basic.types}, \ref{special}). & + ~(\ref{term.trivial.type}, \ref{special}). & \tcode{T} and \tcode{U} shall be complete types, \cv{}~\keyword{void}, or arrays of unknown bound. \\ \rowsep @@ -20812,7 +20813,7 @@ \indexlibraryglobal{is_layout_compatible}% \tcode{template}\br \tcode{struct is_layout_compatible;} & - \tcode{T} and \tcode{U} are layout-compatible\iref{basic.types} & + \tcode{T} and \tcode{U} are layout-compatible\iref{term.layout.compatible.type} & \tcode{T} and \tcode{U} shall be complete types, \cv{}~\keyword{void}, or arrays of unknown bound. \\ \rowsep @@ -20874,7 +20875,7 @@ \pnum For the purpose of defining the templates in this subclause, a function call expression \tcode{declval()} for any type \tcode{T} -is considered to be a trivial~(\ref{basic.types}, \ref{special}) function call +is considered to be a trivial~(\ref{term.trivial.type}, \ref{special}) function call that is not an odr-use\iref{term.odr.use} of \tcode{declval} in the context of the corresponding definition notwithstanding the restrictions of~\ref{declval}.