Skip to content

[lib] Put \constraints on a line of its own. #3548

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
Dec 14, 2019
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
3 changes: 2 additions & 1 deletion source/containers.tex
Original file line number Diff line number Diff line change
Expand Up @@ -3478,7 +3478,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{N == 0} or \tcode{is_swappable_v<T>} is \tcode{true}.
\constraints
\tcode{N == 0} or \tcode{is_swappable_v<T>} is \tcode{true}.

\pnum
\effects
Expand Down
12 changes: 8 additions & 4 deletions source/diagnostics.tex
Original file line number Diff line number Diff line change
Expand Up @@ -1128,7 +1128,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_error_code_enum_v<ErrorCodeEnum>} is \tcode{true}.
\constraints
\tcode{is_error_code_enum_v<ErrorCodeEnum>} is \tcode{true}.

\pnum
\ensures
Expand Down Expand Up @@ -1156,7 +1157,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_error_code_enum_v<ErrorCodeEnum>} is \tcode{true}.
\constraints
\tcode{is_error_code_enum_v<ErrorCodeEnum>} is \tcode{true}.

\pnum
\ensures
Expand Down Expand Up @@ -1336,7 +1338,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_error_condition_enum_v<ErrorConditionEnum>} is \tcode{true}.
\constraints
\tcode{is_error_condition_enum_v<ErrorConditionEnum>} is \tcode{true}.

\pnum
\ensures
Expand Down Expand Up @@ -1365,7 +1368,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_error_condition_enum_v<ErrorConditionEnum>} is \tcode{true}.
\constraints
\tcode{is_error_condition_enum_v<ErrorConditionEnum>} is \tcode{true}.

\pnum
\ensures
Expand Down
18 changes: 12 additions & 6 deletions source/iostreams.tex
Original file line number Diff line number Diff line change
Expand Up @@ -5554,7 +5554,8 @@

\begin{itemdescr}
\pnum
\constraints The expression \tcode{is >> std::forward<T>(x)} is well-formed when treated as an unevaluated operand.
\constraints
The expression \tcode{is >> std::forward<T>(x)} is well-formed when treated as an unevaluated operand.

\pnum
\effects
Expand Down Expand Up @@ -6764,7 +6765,8 @@

\begin{itemdescr}
\pnum
\constraints The expression \tcode{os << x} is well-formed when treated as an unevaluated operand.
\constraints
The expression \tcode{os << x} is well-formed when treated as an unevaluated operand.

\pnum
\effects
Expand Down Expand Up @@ -7780,7 +7782,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{SAlloc} is a type that
\constraints
\tcode{SAlloc} is a type that
qualifies as an allocator\iref{container.requirements.general}.

\pnum
Expand Down Expand Up @@ -7865,7 +7868,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_same_v<SAlloc,Allocator>} is \tcode{false}.
\constraints
\tcode{is_same_v<SAlloc,Allocator>} is \tcode{false}.

\pnum
\effects
Expand Down Expand Up @@ -8649,7 +8653,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_same_v<SAlloc,Allocator>} is \tcode{false}.
\constraints
\tcode{is_same_v<SAlloc,Allocator>} is \tcode{false}.

\pnum
\effects
Expand Down Expand Up @@ -8974,7 +8979,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_same_v<SAlloc,Allocator>} is \tcode{false}.
\constraints
\tcode{is_same_v<SAlloc,Allocator>} is \tcode{false}.

\pnum
\effects
Expand Down
3 changes: 2 additions & 1 deletion source/iterators.tex
Original file line number Diff line number Diff line change
Expand Up @@ -4211,7 +4211,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{Iterator} satisfies \libconcept{copy_constructible}.
\constraints
\tcode{Iterator} satisfies \libconcept{copy_constructible}.

\pnum
\expects
Expand Down
3 changes: 2 additions & 1 deletion source/lib-intro.tex
Original file line number Diff line number Diff line change
Expand Up @@ -592,7 +592,8 @@
\requires the preconditions for calling the function.

\item
\constraints the conditions for the function's participation
\constraints
the conditions for the function's participation
in overload resolution\iref{over.match}.
\begin{note}
Failure to meet such a condition results in the function's silent non-viability.
Expand Down
15 changes: 10 additions & 5 deletions source/support.tex
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_integral_v<IntType>} is \tcode{true}.
\constraints
\tcode{is_integral_v<IntType>} is \tcode{true}.

\pnum
\effects
Expand All @@ -362,7 +363,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_integral_v<IntType>} is \tcode{true}.
\constraints
\tcode{is_integral_v<IntType>} is \tcode{true}.

\pnum
\effects
Expand All @@ -381,7 +383,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_integral_v<IntType>} is \tcode{true}.
\constraints
\tcode{is_integral_v<IntType>} is \tcode{true}.

\pnum
\effects
Expand All @@ -397,7 +400,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_integral_v<IntType>} is \tcode{true}.
\constraints
\tcode{is_integral_v<IntType>} is \tcode{true}.

\pnum
\effects
Expand Down Expand Up @@ -509,7 +513,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_integral_v<IntType>} is \tcode{true}.
\constraints
\tcode{is_integral_v<IntType>} is \tcode{true}.

\pnum
\effects
Expand Down
9 changes: 6 additions & 3 deletions source/utilities.tex
Original file line number Diff line number Diff line change
Expand Up @@ -1261,7 +1261,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_move_constructible_v<$\tcode{T}_i$>} is \tcode{true} for all $i$.
\constraints
\tcode{is_move_constructible_v<$\tcode{T}_i$>} is \tcode{true} for all $i$.

\pnum
\effects
Expand Down Expand Up @@ -9195,7 +9196,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_move_constructible_v<D>} is \tcode{true}.
\constraints
\tcode{is_move_constructible_v<D>} is \tcode{true}.

\pnum
\requires If \tcode{D} is not a reference type,
Expand Down Expand Up @@ -9301,7 +9303,8 @@

\begin{itemdescr}
\pnum
\constraints \tcode{is_move_assignable_v<D>} is \tcode{true}.
\constraints
\tcode{is_move_assignable_v<D>} is \tcode{true}.

\pnum
\requires If \tcode{D} is not a reference type, \tcode{D} shall meet the
Expand Down
4 changes: 2 additions & 2 deletions tools/check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ grep -n 'opt{}' *.tex && exit 1
grep -n "// not defined" $texfiles | sed 's/$/ <--- use \\notdef instead/' | grep . && exit 1

# Library element introducer followed by stuff.
grep -ne '^\\\(contraints\|mandates\|expects\|effects\|sync\|ensures\|returns\|throws\|complexity\|remarks\|errors\).\+$' $texfiles && exit 1
# Fixup: sed 's/^\\\(contraints\|mandates\|expects\|effects\|sync\|ensures\|returns\|throws\|complexity\|remarks\|errors\)\s*\(.\)/\\\1\n\2/'
grep -ne '^\\\(constraints\|mandates\|expects\|effects\|sync\|ensures\|returns\|throws\|complexity\|remarks\|errors\).\+$' $texfiles && exit 1
# Fixup: sed 's/^\\\(constraints\|mandates\|expects\|effects\|sync\|ensures\|returns\|throws\|complexity\|remarks\|errors\)\s*\(.\)/\\\1\n\2/'
# Fixup: sed 's/^\\ //'

# Change marker in [diff] followed by stuff.
Expand Down