From 68f35b795fb8667d12860dc0562b22ce9f2947b1 Mon Sep 17 00:00:00 2001 From: Eisenwave Date: Sun, 5 Apr 2026 17:18:56 +0200 Subject: [PATCH] P4012R1 Value-preserving consteval broadcast to simd::vec Fixes NB DE-286 (C++26 CD). --- source/numerics.tex | 36 ++++++++++++++++-------------------- 1 file changed, 16 insertions(+), 20 deletions(-) diff --git a/source/numerics.tex b/source/numerics.tex index 31a2e217d6..acd7398f19 100644 --- a/source/numerics.tex +++ b/source/numerics.tex @@ -17899,7 +17899,7 @@ // \ref{simd.ctor}, \tcode{basic_vec} constructors template - constexpr explicit(@\seebelow@) basic_vec(U&& value) noexcept; + constexpr basic_vec(U&& value) noexcept; template constexpr explicit(@\seebelow@) basic_vec(const basic_vec&) noexcept; template @@ -18026,7 +18026,7 @@ \indexlibraryctor{basic_vec} \begin{itemdecl} -template constexpr explicit(@\seebelow@) basic_vec(U&& value) noexcept; +template constexpr basic_vec(U&& value) noexcept; \end{itemdecl} \begin{itemdescr} @@ -18035,29 +18035,25 @@ \pnum \constraints -\tcode{U} satisfies \tcode{\exposconcept{explicitly-convertible-to}}. +\begin{itemize} +\item +\tcode{U} satisfies \tcode{\libconcept{convertible_to}} and +\tcode{From} is not an arithmetic type and +does not satisfy \exposconcept{constexpr-wrapper-like}, +\item +\tcode{From} is an arithmetic type and +the conversion from \tcode{From} to \tcode{value_type} +is value-preserving\iref{simd.general}, or +\item +\tcode{From} satisfies \exposconcept{constexpr-wrapper-like}, +\tcode{remove_cvref_t} is an arithmetic type, and +\tcode{From::value} is representable by \tcode{value_type}. +\end{itemize} \pnum \effects Initializes each element to the value of the argument after conversion to \tcode{value_type}. - -\pnum -\remarks -The expression inside \tcode{explicit} evaluates to \tcode{false} if and only if -\tcode{U} satisfies \tcode{\libconcept{convertible_to}}, and either -\begin{itemize} - \item - \tcode{From} is not an arithmetic type and does not satisfy - \exposconcept{constexpr-wrapper-like}, - \item - \tcode{From} is an arithmetic type and the conversion from \tcode{From} to - \tcode{value_type} is value-preserving\iref{simd.general}, or - \item - \tcode{From} satisfies \exposconcept{constexpr-wrapper-like}, - \tcode{remove_cvref_t} is an arithmetic type, and - \tcode{From::value} is representable by \tcode{value_type}. -\end{itemize} \end{itemdescr} \indexlibraryctor{basic_vec}