Skip to content

Commit bbb371f

Browse files
committed
LWG4382 The simd::basic_mask(bool) overload needs to be more constrained
1 parent 7faca53 commit bbb371f

File tree

1 file changed

+12
-6
lines changed

1 file changed

+12
-6
lines changed

source/numerics.tex

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20031,13 +20031,16 @@
2003120031
constexpr basic_mask() noexcept = default;
2003220032

2003320033
// \ref{simd.mask.ctor}, \tcode{basic_mask} constructors
20034-
constexpr explicit basic_mask(value_type) noexcept;
20034+
constexpr explicit basic_mask(@\libconcept{same_as}@<value_type> auto) noexcept;
2003520035
template<size_t UBytes, class UAbi>
2003620036
constexpr explicit basic_mask(const basic_mask<UBytes, UAbi>&) noexcept;
2003720037
template<class G>
2003820038
constexpr explicit basic_mask(G&& gen);
20039-
constexpr basic_mask(const bitset<size()>& b) noexcept;
20040-
constexpr explicit basic_mask(@\libconcept{unsigned_integral}@ auto val) noexcept;
20039+
template<@\libconcept{same_as}@<bitset<size()>> T>
20040+
constexpr basic_mask(const T& b) noexcept;
20041+
template<@\libconcept{unsigned_integral}@ T>
20042+
requires (!@\libconcept{same_as}@<T, value_type>)
20043+
constexpr explicit basic_mask(T val) noexcept;
2004120044

2004220045
// \ref{simd.mask.subscr}, \tcode{basic_mask} subscript operators
2004320046
constexpr value_type operator[](@\exposid{simd-size-type}@) const;
@@ -20141,7 +20144,7 @@
2014120144

2014220145
\indexlibraryctor{basic_mask}
2014320146
\begin{itemdecl}
20144-
constexpr explicit basic_mask(value_type x) noexcept;
20147+
constexpr explicit basic_mask(@\libconcept{same_as}@<value_type> auto) noexcept;
2014520148
\end{itemdecl}
2014620149

2014720150
\begin{itemdescr}
@@ -20193,7 +20196,8 @@
2019320196

2019420197
\indexlibraryctor{basic_mask}
2019520198
\begin{itemdecl}
20196-
constexpr basic_mask(const bitset<size()>& b) noexcept;
20199+
template<@\libconcept{same_as}@<bitset<size()>> T>
20200+
constexpr basic_mask(const T& b) noexcept;
2019720201
\end{itemdecl}
2019820202

2019920203
\begin{itemdescr}
@@ -20205,7 +20209,9 @@
2020520209

2020620210
\indexlibraryctor{basic_mask}
2020720211
\begin{itemdecl}
20208-
constexpr explicit basic_mask(@\libconcept{unsigned_integral}@ auto val) noexcept;
20212+
template<@\libconcept{unsigned_integral}@ T>
20213+
requires (!@\libconcept{same_as}@<T, value_type>)
20214+
constexpr explicit basic_mask(T val) noexcept;
2020920215
\end{itemdecl}
2021020216

2021120217
\begin{itemdescr}

0 commit comments

Comments
 (0)