Skip to content

Commit f32810a

Browse files
committed
fixups: consistent use of \keyword for const, always using it in prose because that seems to be the consistent style in the standard, removed informational-only JMB comments
1 parent 9fac1ff commit f32810a

File tree

3 files changed

+16
-16
lines changed

3 files changed

+16
-16
lines changed

source/basic.tex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7376,8 +7376,8 @@
73767376
Within the predicate of a contract assertion,
73777377
\grammarterm{id-expression}s referring to
73787378
variables declared outside the contract assertion
7379-
are const\iref{expr.prim.id.unqual},
7380-
\tcode{this} is a pointer to const\iref{expr.prim.this},
7379+
are \keyword{const}\iref{expr.prim.id.unqual},
7380+
\tcode{this} is a pointer to \keyword{const}\iref{expr.prim.this},
73817381
and the result object can be named
73827382
if a \grammarterm{result-name-introducer}\iref{dcl.contract.res} has been specified.
73837383
\end{note}
@@ -7743,7 +7743,7 @@
77437743
The contract-violation handler
77447744
shall have a single parameter
77457745
of type
7746-
``lvalue reference to \tcode{const} \tcode{std::\-contracts::\-contract_violation}''
7746+
``lvalue reference to \keyword{const} \tcode{std::\-contracts::\-contract_violation}''
77477747
and shall return \tcode{void}.
77487748
The contract-violation handler
77497749
may have a non-throwing exception specification.

source/declarations.tex

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4595,7 +4595,7 @@
45954595
or neither do.
45964596
\end{itemize}
45974597
If this condition is not met
4598-
solely due to the comparison of two \grammarterm{lambda-expression}s %JMB: In P2900 lambda-expressions was not in grammar font
4598+
solely due to the comparison of two \grammarterm{lambda-expression}s
45994599
that are contained within $P_1$ and $P_2$,
46004600
no diagnostic is required.
46014601

@@ -4640,13 +4640,13 @@
46404640
a non-reference parameter of \placeholder{f},
46414641
that parameter
46424642
and the corresponding parameter on all declarations of \placeholder{f}
4643-
shall have const type. %JMB: const was in code font in 2900
4643+
shall have \keyword{const} type.
46444644
\begin{note}
46454645
This requirement applies
46464646
even to declarations that do not specify the \grammarterm{postcondition-specifier}.
46474647
Parameters with array or function type
4648-
will decay to non-const types %JMB: const was in code font in 2900
4649-
even if a \tcode{const} qualifier is present.
4648+
will decay to non-\keyword{const} types
4649+
even if a \keyword{const} qualifier is present.
46504650
\begin{example}
46514651
\begin{codeblock}
46524652
int f(const int i[10])
@@ -4726,7 +4726,7 @@
47264726
appertains to the result binding so introduced.
47274727
\begin{note}
47284728
An \grammarterm{id-expression}
4729-
that names a result binding is a const lvalue\iref{expr.prim.id.unqual}. %JMB: This const was code font in P2900
4729+
that names a result binding is a \keyword{const} lvalue\iref{expr.prim.id.unqual}.
47304730
\end{note}
47314731

47324732
\begin{example}
@@ -7152,7 +7152,7 @@
71527152

71537153
\pnum
71547154
A coroutine behaves as if
7155-
the top-level cv-qualifiers in all %JMB: P2900 used math font for cv here
7155+
the top-level cv-qualifiers in all
71567156
\grammarterm{parameter-declaration}s in the declarator
71577157
of its \grammarterm{function-definition}
71587158
were removed and
@@ -7272,7 +7272,7 @@
72727272
argument list. The first argument is the amount of space requested, and
72737273
is a prvalue of type \tcode{std::size_t}.
72747274
The lvalues $\tcode{p}_1 \dotsc \tcode{p}_n$
7275-
with their original types (including cv-qualifiers) %JMB: P2900 used math font for cv here
7275+
with their original types (including cv-qualifiers)
72767276
are the successive arguments.
72777277
If no viable function is found\iref{over.match.viable},
72787278
overload resolution is performed again
@@ -9875,7 +9875,7 @@
98759875
\grammarterm{typedef-name},
98769876
variable (including a structured binding declaration),
98779877
structured binding,
9878-
result binding\iref{dcl.contract.res}, %JMB: In P2900 the comma was in the wrong place
9878+
result binding\iref{dcl.contract.res},
98799879
non-static data member,
98809880
function,
98819881
enumeration, or

source/expressions.tex

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1286,7 +1286,7 @@
12861286
and including in the bodies of nested \grammarterm{lambda-expression}s), %JMB: I think this is hard to parse, and lori suggested removing the second comma. It's "If (X including Y) and Z then A" but we have "If X and Y, and Z, then A". Should we make this "If X (including Y) and Z, A"
12871287
and the current class
12881288
encloses the contract assertion,
1289-
\tcode{const} is combined with the \grammarterm{cv-qualifier-seq}
1289+
\keyword{const} is combined with the \grammarterm{cv-qualifier-seq}
12901290
used to generate the resulting type (see below).
12911291

12921292
\pnum
@@ -1619,7 +1619,7 @@
16191619
\item
16201620
a variable
16211621
declared outside of $C$
1622-
of object type \tcode{T}, %JMB: I removed an or that was here in P2900
1622+
of object type \tcode{T},
16231623
\item
16241624
a variable or template parameter
16251625
declared outside of $C$
@@ -1630,7 +1630,7 @@
16301630
whose corresponding variable
16311631
is declared outside of $C$,
16321632
\end{itemize}
1633-
then the type of the expression is \tcode{const}~\tcode{T}.
1633+
then the type of the expression is \keyword{const}~\tcode{T}.
16341634

16351635
\pnum
16361636
\begin{example}
@@ -1903,7 +1903,7 @@
19031903
\item
19041904
a variable
19051905
declared outside of $C$
1906-
of object type \tcode{T}, %JMB: I removed an or that was here in P2900
1906+
of object type \tcode{T},
19071907
\item
19081908
a variable
19091909
declared outside of $C$
@@ -1913,7 +1913,7 @@
19131913
whose corresponding variable
19141914
is declared outside of $C$,
19151915
\end{itemize}
1916-
then the type of the expression is \tcode{const}~\tcode{T}.
1916+
then the type of the expression is \keyword{const}~\tcode{T}.
19171917

19181918

19191919
\pnum

0 commit comments

Comments
 (0)