Skip to content

Replace \term+\indextext pairs with \defn(x). #1665

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 30, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 3 additions & 6 deletions source/declarators.tex
Original file line number Diff line number Diff line change
Expand Up @@ -673,12 +673,10 @@


\pnum
\indextext{lvalue reference}%
\indextext{rvalue reference}%
A reference type that is declared using \tcode{\&} is called an
\term{lvalue reference}, and a reference type that
\defn{lvalue reference}, and a reference type that
is declared using \tcode{\&\&} is called an
\term{rvalue reference}. Lvalue references and
\defn{rvalue reference}. Lvalue references and
rvalue references are distinct types. Except where explicitly noted, they are
semantically equivalent and commonly referred to as references.

Expand Down Expand Up @@ -2943,8 +2941,7 @@
\end{note}

\pnum
\indextext{aggregate!elements}%
The \term{elements} of an aggregate are:
The \defnx{elements}{aggregate!elements} of an aggregate are:
\begin{itemize}
\item
for an array, the array elements in increasing subscript order, or
Expand Down
18 changes: 6 additions & 12 deletions source/derived.tex
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@
an incompletely defined class (Clause~\ref{class}).
The class denoted by the \grammarterm{class-or-decltype} of
a \grammarterm{base-specifier} is called a
\indextext{base class!direct}%
\term{direct base class}
\defnx{direct base class}{base class!direct}
for the class being defined.
\indextext{base class}%
\indextext{derivation|see{inheritance}}%
Expand All @@ -69,8 +68,7 @@
\grammarterm{class-name}, the program is ill-formed. A class \tcode{B} is a
base class of a class \tcode{D} if it is a direct base class of
\tcode{D} or a direct base class of one of \tcode{D}'s base classes.
\indextext{base class!indirect}%
A class is an \term{indirect} base class of another if it is a base
A class is an \defnx{indirect}{base class!indirect} base class of another if it is a base
class but not a direct base class. A class is said to be (directly or
indirectly) \term{derived} from its (direct or indirect) base
classes.
Expand All @@ -82,8 +80,7 @@
Unless redeclared in the derived class, members of a base class are also
considered to be members of the derived class.
Members of a base class other than constructors are said to be
\indextext{inheritance}%
\term{inherited}
\defnx{inherited}{inheritance}
by the derived class. Constructors of a base class
can also be inherited as described in~\ref{namespace.udecl}.
Inherited members can be referred to in
Expand Down Expand Up @@ -577,13 +574,12 @@
\rSec1[class.virtual]{Virtual functions}%
\indextext{virtual function|(}%
\indextext{type!polymorphic}%
\indextext{class!polymorphic}

\pnum
\begin{note}
Virtual functions support dynamic binding and object-oriented
programming. \end{note} A class that declares or inherits a virtual function is
called a \term{polymorphic class}.
called a \defnx{polymorphic class}{class!polymorphic}.

\pnum
If a virtual member function \tcode{vf} is declared in a class
Expand Down Expand Up @@ -910,7 +906,6 @@
\indextext{virtual function|)}

\rSec1[class.abstract]{Abstract classes}%
\indextext{class!abstract}

\pnum
\begin{note}
Expand All @@ -922,15 +917,14 @@
\end{note}

\pnum
An \term{abstract class} is a class that can be used only
An \defnx{abstract class}{class!abstract} is a class that can be used only
as a base class of some other class; no objects of an abstract class can
be created except as subobjects of a class derived from it. A class is
abstract if it has at least one \term{pure virtual function}.
\begin{note}
Such a function might be inherited: see below.
\end{note}
\indextext{virtual function!pure}%
A virtual function is specified \term{pure} by using a
A virtual function is specified \defnx{pure}{virtual function!pure} by using a
\grammarterm{pure-specifier}~(\ref{class.mem}) in the function declaration
in the class definition.
\indextext{definition!pure virtual function}%
Expand Down
9 changes: 3 additions & 6 deletions source/expressions.tex
Original file line number Diff line number Diff line change
Expand Up @@ -3593,17 +3593,15 @@
type by calling the above-mentioned conversion function, and the
converted operand is used in place of the original operand for the
remainder of this section.
\indextext{object!delete}%
In the first alternative
(\term{delete object}), the value of the operand of \tcode{delete} may
(\defnx{delete object}{object!delete}), the value of the operand of \tcode{delete} may
be a null pointer value, a pointer to a non-array object
created by a previous \grammarterm{new-expression},
or a pointer to a
subobject~(\ref{intro.object}) representing a base class of such an
object (Clause~\ref{class.derived}). If not, the behavior is undefined.
\indextext{array!\idxcode{delete}}%
\indextext{\idxcode{delete}!array}%
In the second alternative (\term{delete array}), the value of the
In the second alternative (\defnx{delete array}{\idxcode{delete}!array}), the value of the
operand of \tcode{delete}
may be a null pointer value or a pointer value
that resulted from
Expand Down Expand Up @@ -5199,8 +5197,7 @@
the conversion sequence contains only the conversions above.

\pnum
\indextext{expression!constant}%
A \term{constant expression} is either
A \defnx{constant expression}{expression!constant} is either
a glvalue core constant expression that refers to
an entity that is a permitted result of a constant expression (as defined below), or
a prvalue core constant expression whose value
Expand Down
29 changes: 9 additions & 20 deletions source/lib-intro.tex
Original file line number Diff line number Diff line change
Expand Up @@ -510,14 +510,10 @@
For non-reserved replacement and handler functions,
Clause~\ref{language.support} specifies two behaviors for the functions in question:
their required and default behavior.
The
\term{default behavior}
The \defnx{default behavior}{behavior!default}
describes a function definition provided by the implementation.
\indextext{behavior!default}%
The
\term{required behavior}
The \defnx{required behavior}{behavior!required}
describes the semantics of a function definition provided by
\indextext{behavior!required}%
either the implementation or a \Cpp program.
Where no distinction is explicitly made in the description, the
behavior described is the required behavior.
Expand Down Expand Up @@ -598,8 +594,7 @@

\pnum
Several types defined in Clause~\ref{input.output} are
\term{enumerated types}.
\indextext{type!enumerated}%
\defnx{enumerated types}{type!enumerated}.
Each enumerated type may be implemented as an enumeration or as a synonym for
an enumeration.\footnote{Such as an integer type, with constant integer
values~(\ref{basic.fundamental}).}
Expand Down Expand Up @@ -630,8 +625,7 @@
\pnum
Several types defined in Clauses~\ref{\firstlibchapter} through~\ref{\lastlibchapter}
and Annex~\ref{depr} are
\term{bitmask types}.
\indextext{type!bitmask}%
\defnx{bitmask types}{type!bitmask}.
Each bitmask type can be implemented as an
enumerated type that overloads certain operators, as an integer type,
or as a
Expand Down Expand Up @@ -731,9 +725,8 @@
uppercase letters in the basic execution character set.
\item
The
\term{decimal-point character}
\defnx{decimal-point character}{character!decimal-point}
is the
\indextext{character!decimal-point}%
(single-byte) character used by functions that convert between a (single-byte)
character sequence and a value of one of the floating-point types.
It is used
Expand Down Expand Up @@ -781,9 +774,8 @@

\pnum
A
\indextext{string!null-terminated byte}%
\indextext{NTBS}%
\term{null-terminated byte string},
\defnx{null-terminated byte string}{string!null-terminated byte},
or \ntbs,
is a character sequence whose highest-addressed element
with defined content has the value zero
Expand Down Expand Up @@ -820,8 +812,7 @@
\pnum
A
\indextext{NTBS}%
\indextext{NTBS!static}%
\term{static} \ntbs
\defnx{static}{NTBS!static} \ntbs
is an \ntbs with
static storage duration.\footnote{A string literal, such as
\tcode{"abc"},
Expand All @@ -842,9 +833,8 @@

\pnum
A
\term{static} \ntmbs
\defnx{static}{NTMBS!static} \ntmbs
is an \ntmbs with static storage duration.
\indextext{NTMBS!static}%
\indextext{NTMBS}%

\rSec3[functions.within.classes]{Functions within classes}
Expand Down Expand Up @@ -1268,11 +1258,10 @@

\pnum
Two kinds of implementations are defined:
\term{hosted}
\defnx{hosted}{implementation!hosted}
and
\term{freestanding}~(\ref{intro.compliance}).
For a hosted implementation, this International Standard
\indextext{implementation!hosted}%
describes the set of available headers.

\pnum
Expand Down
22 changes: 8 additions & 14 deletions source/special.tex
Original file line number Diff line number Diff line change
Expand Up @@ -150,10 +150,9 @@

\pnum
\indextext{constructor!inheritance of}%
\indextext{constructor!default}%
\indextext{constructor!non-trivial}%
A
\term{default}
\defnx{default}{constructor!default}
constructor for a class
\tcode{X}
is a constructor of class
Expand Down Expand Up @@ -236,11 +235,10 @@
\defnx{non-trivial}{constructor!default!non-trivial}.

\pnum
\indextext{constructor!implicitly defined}%
A default constructor
that is defaulted and not defined as deleted
is
\term{implicitly defined}
\defnx{implicitly defined}{constructor!implicitly defined}
when it is odr-used~(\ref{basic.def.odr})
to create an object of its class type~(\ref{intro.object})
or when it is explicitly defaulted after its first declaration.
Expand Down Expand Up @@ -657,14 +655,13 @@

\pnum
\indextext{conversion!class}%
\indextext{conversion!user-defined}%
\indextext{constructor, conversion by|see{conversion, user-defined}}%
\indextext{conversion function|see{conversion, user-defined}}%
\indextext{conversion!implicit}%
Type conversions of class objects can be specified by constructors and
by conversion functions.
These conversions are called
\term{user-defined conversions}
\defnx{user-defined conversions}{conversion!user-defined}
and are used for implicit type conversions (Clause~\ref{conv}),
for initialization~(\ref{dcl.init}),
and for explicit type conversions~(\ref{expr.cast}, \ref{expr.static.cast}).
Expand Down Expand Up @@ -735,8 +732,7 @@
the types of its parameters (if any)
to the type of its class.
Such a constructor is called a
\indexdefn{constructor!converting}%
\term{converting constructor}.
\defnx{converting constructor}{constructor!converting}.
\begin{example}

\indextext{Jessie}%
Expand Down Expand Up @@ -1047,11 +1043,10 @@
\defnx{non-trivial}{destructor!non-trivial}.

\pnum
\indextext{destructor!implicitly defined}%
A destructor
that is defaulted and not defined as deleted
is
\term{implicitly defined}
\defnx{implicitly defined}{destructor!implicitly defined}
when it is odr-used~(\ref{basic.def.odr})
or when it is explicitly defaulted after its first declaration.

Expand Down Expand Up @@ -2543,9 +2538,8 @@
\end{example}

\pnum
\indextext{constructor!copy!implicitly declared}%
If the class definition does not explicitly declare a copy constructor,
a non-explicit one is declared \term{implicitly}.
a non-explicit one is declared \defnx{implicitly}{constructor!copy!implicitly declared}.
If the class definition declares a move
constructor or move assignment operator, the implicitly declared copy
constructor is defined as deleted; otherwise, it is defined as
Expand Down Expand Up @@ -2792,9 +2786,9 @@
\end{note}

\pnum
\indextext{assignment operator!copy!implicitly declared}%
If the class definition does not explicitly declare a copy assignment operator,
one is declared \term{implicitly}. If the class definition declares a move
one is declared \defnx{implicitly}{assignment operator!copy!implicitly declared}.
If the class definition declares a move
constructor or move assignment operator, the implicitly declared copy
assignment operator is defined as deleted; otherwise, it is defined as
defaulted~(\ref{dcl.fct.def}).
Expand Down
4 changes: 2 additions & 2 deletions source/strings.tex
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
\pnum
This Clause describes components for manipulating sequences of
any non-array POD~(\ref{basic.types}) type.
Such types are called \term{char-like types},\indextext{char-like type}
Such types are called \defnx{char-like types}{char-like type},
and objects of
char-like types are called \term{char-like objects}\indextext{char-like object} or
char-like types are called \defnx{char-like objects}{char-like object} or
simply \term{characters}.

\pnum
Expand Down
6 changes: 3 additions & 3 deletions source/threads.tex
Original file line number Diff line number Diff line change
Expand Up @@ -4261,7 +4261,7 @@

\begin{itemdescr}
\pnum
\effects Constructs an \indexdefn{empty \tcode{future} object}\term{empty}
\effects Constructs an \defnx{empty}{empty \tcode{future} object}
\tcode{future} object that does not refer to a
shared state.

Expand Down Expand Up @@ -4547,8 +4547,8 @@

\begin{itemdescr}
\pnum
\effects Constructs an \indexdefn{empty \tcode{shared_future}
object}\term{empty} \tcode{shared_future} object that does not refer to a
\effects Constructs an \defnx{empty}{empty \tcode{shared_future} object}
\tcode{shared_future} object that does not refer to a
shared state.

\pnum
Expand Down
Loading