Skip to content

Commit 10ba2aa

Browse files
committed
[std] Replace other forbidden words in notes and examples
1 parent 270dc04 commit 10ba2aa

13 files changed

+35
-38
lines changed

source/classes.tex

+2-2
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
\grammarterm{class-head} omits the
6666
\grammarterm{class-head-name} defines an \defnadj{unnamed}{class}.
6767
\begin{note}
68-
An unnamed class thus can't
68+
An unnamed class thus cannot
6969
be \tcode{final}.
7070
\end{note}
7171
Otherwise, the \grammarterm{class-name} is an \grammarterm{identifier};
@@ -1025,7 +1025,7 @@
10251025
Programs shall not define implicitly-declared special member functions.
10261026

10271027
\pnum
1028-
Programs may explicitly refer to implicitly-declared special member functions.
1028+
Programs can explicitly refer to implicitly-declared special member functions.
10291029
\begin{example}
10301030
A program may explicitly call or form a pointer to member
10311031
to an implicitly-declared special member function.

source/compatibility.tex

+7-7
Original file line numberDiff line numberDiff line change
@@ -1350,7 +1350,7 @@
13501350
\rationale
13511351
Prevents accidental uses of trigraphs in non-raw string literals and comments.
13521352
\effect
1353-
Valid \CppXIV{} code that uses trigraphs may not be valid or may have different
1353+
Valid \CppXIV{} code that uses trigraphs can be invalid or may have different
13541354
semantics in this revision of \Cpp{}. Implementations may choose to
13551355
translate trigraphs as specified in \CppXIV{} if they appear outside of a raw
13561356
string literal, as part of the \impldef{mapping input source file characters
@@ -1476,7 +1476,7 @@
14761476
\rationale
14771477
Better interaction with other language features.
14781478
\effect
1479-
Valid \CppXIV{} code that uses inheriting constructors may not be valid
1479+
Valid \CppXIV{} code that uses inheriting constructors can be invalid
14801480
or may have different semantics. A \grammarterm{using-declaration}
14811481
that names a constructor now makes the corresponding base class constructors
14821482
visible to initializations of the derived class
@@ -2157,7 +2157,7 @@
21572157
\rationale
21582158
Avoid hard to diagnose or non-portable constructs.
21592159
\effect
2160-
Names of attribute identifiers may not be used as macro names. Valid \CppIII{}
2160+
It is not allowed to use names of attribute identifiers as macro names. Valid \CppIII{}
21612161
code that defines \tcode{override}, \tcode{final},
21622162
\tcode{carries_dependency}, or \tcode{noreturn} as macros is invalid in this
21632163
revision of \Cpp{}.
@@ -2236,7 +2236,7 @@
22362236
Lack of specification of complexity of \tcode{size()} resulted in
22372237
divergent implementations with inconsistent performance characteristics.
22382238
\effect
2239-
Some container implementations that conform to \CppIII{} may not conform to the
2239+
It is possible that some container implementations that conform to \CppIII{} do not conform to the
22402240
specified \tcode{size()} requirements in this revision of \Cpp{}. Adjusting
22412241
containers such as \tcode{std::list} to the stricter requirements may require
22422242
incompatible changes.
@@ -2343,7 +2343,7 @@
23432343
\effect
23442344
Valid \CppIII{} code that uses implementation-specific knowledge about the
23452345
binary representation of the required template specializations of
2346-
\tcode{std::complex} may not be compatible with this revision of \Cpp{}.
2346+
\tcode{std::complex} can be incompatible with this revision of \Cpp{}.
23472347

23482348
\rSec2[diff.cpp03.locale]{\ref{localization}: localization library}
23492349

@@ -2941,7 +2941,7 @@
29412941

29422942
\diffref{dcl.fct} [see \ref{expr.sizeof}]
29432943
\change
2944-
In \Cpp{}, types may not be defined in return or parameter types.
2944+
In \Cpp{}, it is not allowed to define types in return or parameter types.
29452945
In C, these type definitions are allowed.
29462946

29472947
Example:
@@ -3256,7 +3256,7 @@
32563256

32573257
\diffref{class.member.lookup}
32583258
\change
3259-
In \Cpp{}, a \grammarterm{typedef-name} may not be redeclared in a class definition after being used in that definition.
3259+
In \Cpp{}, it is not allowed to redeclare a \grammarterm{typedef-name} in a class definition after being used in that definition.
32603260

32613261
Example:
32623262
\begin{codeblock}

source/concepts.tex

+1-1
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,7 @@
623623
\begin{note}
624624
This precludes calling unconstrained program-defined overloads of
625625
\tcode{swap}. When the deleted overload is viable, program-defined overloads
626-
need to be more specialized\iref{temp.func.order} to be selected.
626+
are expected to be more specialized\iref{temp.func.order} to be selected.
627627
\end{note}
628628

629629
\item

source/containers.tex

+1-1
Original file line numberDiff line numberDiff line change
@@ -22334,7 +22334,7 @@
2233422334
\pnum
2233522335
\begin{note}
2233622336
Concrete accessor policies can impose preconditions for their \tcode{access} function.
22337-
However, they can not.
22337+
However, it is possible that they do not.
2233822338
For example, an accessor where
2233922339
\tcode{p} is \tcode{span<A::element_type, dynamic_extent>} and
2234022340
\tcode{access(p, i)} returns \tcode{p[i \% p.size()]}

source/declarations.tex

+2-2
Original file line numberDiff line numberDiff line change
@@ -6291,7 +6291,7 @@
62916291
\end{itemize}
62926292

62936293
\begin{note}
6294-
As indicated above, such conversions are not allowed at the top level in
6294+
As indicated above, such conversions are not possible at the top level in
62956295
list-initializations.
62966296
\end{note}
62976297
\begin{example}
@@ -9377,7 +9377,7 @@
93779377
[[maybe_unused]] x:
93789378
}
93799379
\end{codeblock}
9380-
Implementations should not warn that \tcode{b} or \tcode{x} is unused,
9380+
Implementations are discouraged from warning that \tcode{b} or \tcode{x} is unused,
93819381
whether or not \tcode{NDEBUG} is defined.
93829382
\end{example}
93839383

source/exceptions.tex

+3-2
Original file line numberDiff line numberDiff line change
@@ -987,8 +987,9 @@
987987
A defaulted declaration does not require the
988988
exception specification of a base member function to be evaluated
989989
until the implicit exception specification of the derived
990-
function is needed, but an explicit \grammarterm{noexcept-specifier} needs
991-
the implicit exception specification to compare against.
990+
function is needed, but an explicit \grammarterm{noexcept-specifier}
991+
compares against
992+
the implicit exception specification.
992993
\end{note}
993994
\end{itemize}
994995
The exception specification of a defaulted

source/expressions.tex

+1-1
Original file line numberDiff line numberDiff line change
@@ -1443,7 +1443,7 @@
14431443
\end{codeblock}
14441444
In each case, the constraints of \tcode{f} are not satisfied.
14451445
In the declaration of \tcode{p2},
1446-
those constraints need to be satisfied
1446+
those constraints are expected to be satisfied
14471447
even though
14481448
\tcode{f} is an unevaluated operand\iref{term.unevaluated.operand}.
14491449
\end{example}

source/iterators.tex

+1-1
Original file line numberDiff line numberDiff line change
@@ -1213,7 +1213,7 @@
12131213
the program is ill-formed, no diagnostic required.
12141214
\begin{note}
12151215
This precludes calling unconstrained \tcode{std::iter_swap}. When the deleted
1216-
overload is viable, program-defined overloads need to be more
1216+
overload is viable, program-defined overloads are expected to be more
12171217
specialized\iref{temp.func.order} to be selected.
12181218
\end{note}
12191219

source/memory.tex

+3-8
Original file line numberDiff line numberDiff line change
@@ -2115,7 +2115,7 @@
21152115
Given an allocator type \tcode{X}\iref{allocator.requirements.general} and
21162116
letting \tcode{A} be a synonym for \tcode{allocator_traits<X>}, the types \tcode{A::pointer},
21172117
\tcode{A::const_pointer}, \tcode{A::void_pointer}, and \tcode{A::const_void_pointer}
2118-
may be used as \tcode{unique_ptr<T, D>::pointer}.
2118+
can be used as \tcode{unique_ptr<T, D>::pointer}.
21192119
\end{example}
21202120

21212121
\rSec4[unique.ptr.single.ctor]{Constructors}
@@ -4852,14 +4852,9 @@
48524852
\pnum
48534853
\tcode{operator()(x, y)} returns \tcode{x.owner_before(y)}.
48544854
\begin{note}
4855-
Note that
4856-
\begin{itemize}
4857-
\item \tcode{operator()} defines a strict weak ordering as defined in~\ref{alg.sorting};
4858-
4859-
\item
4855+
\tcode{operator()} defines a strict weak ordering as defined in~\ref{alg.sorting}.
48604856
\tcode{!operator()(a, b) \&\& !operator()(b, a)} is \tcode{true}
48614857
if and only if \tcode{a.owner_equal(b)} is \tcode{true}.
4862-
\end{itemize}
48634858
\end{note}
48644859

48654860
\rSec3[util.smartptr.owner.hash]{Struct \tcode{owner_hash}}
@@ -6231,7 +6226,7 @@
62316226
A \tcode{synchronized_pool_resource} may be accessed from multiple threads
62326227
without external synchronization
62336228
and may have thread-specific pools to reduce synchronization costs.
6234-
An \tcode{unsynchronized_pool_resource} class may not be accessed
6229+
An \tcode{unsynchronized_pool_resource} class is not permitted to be accessed
62356230
from multiple threads simultaneously
62366231
and thus avoids the cost of synchronization entirely
62376232
in single-threaded applications.

source/support.tex

+1-1
Original file line numberDiff line numberDiff line change
@@ -6182,7 +6182,7 @@
61826182
\begin{example}
61836183
The header \libheader{cstdlib} assuredly
61846184
provides its declarations and definitions within the namespace
6185-
\tcode{std}. It may also provide these names within the
6185+
\tcode{std}. It can also provide these names within the
61866186
global namespace.
61876187
The header \libheader{stdlib.h}
61886188
assuredly provides the same declarations and definitions within

source/templates.tex

+2-2
Original file line numberDiff line numberDiff line change
@@ -6358,7 +6358,7 @@
63586358

63596359
\pnum
63606360
\begin{note}
6361-
An explicit instantiation of a constrained template needs
6361+
An explicit instantiation of a constrained template is expected
63626362
to satisfy that template's associated constraints\iref{temp.constr.decl}.
63636363
The satisfaction of constraints is determined
63646364
% FIXME: What is a "template name"? Does this mean "simple-template-id"?
@@ -6681,7 +6681,7 @@
66816681

66826682
\pnum
66836683
\begin{note}
6684-
An explicit specialization of a constrained template needs
6684+
An explicit specialization of a constrained template is expected
66856685
to satisfy that template's associated constraints\iref{temp.constr.decl}.
66866686
The satisfaction of constraints is determined
66876687
when forming the template name of an explicit specialization

source/threads.tex

+10-9
Original file line numberDiff line numberDiff line change
@@ -57,11 +57,11 @@
5757
in~\ref{res.on.exception.handling}.
5858

5959
\begin{example}
60-
Consider a function in this Clause that is specified to throw exceptions of type
60+
If a function in this Clause that is specified to throw exceptions of type
6161
\tcode{system_error} and specifies error conditions that include
6262
\tcode{operation_not_permitted} for a thread that does not have the privilege to
63-
perform the operation. Assume that, during the execution of this function, an \tcode{errno}
64-
of \tcode{EPERM} is reported by a POSIX API call used by the implementation. Since POSIX
63+
perform the operation, and if during the execution of this function, an \tcode{errno}
64+
of \tcode{EPERM} is reported by a POSIX API call used by the implementation, since POSIX
6565
specifies an \tcode{errno} of \tcode{EPERM} when ``the caller does not have the privilege
6666
to perform the operation'', the implementation maps \tcode{EPERM} to an
6767
\tcode{error_condition} of \tcode{operation_not_permitted}\iref{syserr} and an exception
@@ -2516,8 +2516,9 @@
25162516
\item \tcode{memory_order::consume}: a load operation performs a consume operation on the
25172517
affected memory location.
25182518
\begin{note}
2519-
Prefer \tcode{memory_order::acquire}, which provides stronger guarantees
2520-
than \tcode{memory_order::consume}. Implementations have found it infeasible
2519+
\tcode{memory_order::acquire}, which provides stronger guarantees
2520+
than \tcode{memory_order::consume}, is preferred.
2521+
Implementations have found it infeasible
25212522
to provide performance better than that of \tcode{memory_order::acquire}.
25222523
Specification revisions are under consideration.
25232524
\end{note}
@@ -2606,7 +2607,7 @@
26062607

26072608
\pnum
26082609
\begin{note}
2609-
We do not require that $S$ be consistent with
2610+
It is not necessary for $S$ to be consistent with
26102611
``happens before''\iref{intro.races}.
26112612
This allows more efficient implementation
26122613
of \tcode{memory_order::acquire} and \tcode{memory_order::release}
@@ -2908,14 +2909,14 @@
29082909

29092910
\pnum
29102911
\begin{note}
2911-
Hardware could require an object
2912+
Hardware can require an object
29122913
referenced by an \tcode{atomic_ref}
29132914
to have stricter alignment\iref{basic.align}
29142915
than other objects of type \tcode{T}.
29152916
Further, whether operations on an \tcode{atomic_ref}
2916-
are lock-free could depend on the alignment of the referenced object.
2917+
are lock-free can depend on the alignment of the referenced object.
29172918
For example, lock-free operations on \tcode{std::complex<double>}
2918-
could be supported only if aligned to \tcode{2*alignof(double)}.
2919+
can be supported only if aligned to \tcode{2*alignof(double)}.
29192920
\end{note}
29202921
\end{itemdescr}
29212922

source/utilities.tex

+1-1
Original file line numberDiff line numberDiff line change
@@ -1359,7 +1359,7 @@
13591359
\begin{codeblock}
13601360
return pair<int, double>(5, 3.1415926); // explicit types
13611361
\end{codeblock}
1362-
a \Cpp{} program may contain:
1362+
a \Cpp{} program can contain:
13631363
\begin{codeblock}
13641364
return make_pair(5, 3.1415926); // types are deduced
13651365
\end{codeblock}

0 commit comments

Comments
 (0)