[libcxx-commits] [libcxx] [libc++] <experimental/simd> Add compound assignment operators for simd reference (PR #86761)

Nikolas Klauser via libcxx-commits libcxx-commits at lists.llvm.org
Fri Jul 19 00:24:05 PDT 2024


================
@@ -60,6 +63,24 @@ class __simd_reference {
     return {__s_, __idx_};
   }
 
+#  define _LIBCXX_SIMD_REFERENCE_OP_(__op)                                                                             \
+    template <class _Up, class = decltype(std::declval<value_type&>() __op## = std::declval<_Up>())>                   \
----------------
philnik777 wrote:

Isn't this just `is_assignable`?

https://github.com/llvm/llvm-project/pull/86761


More information about the libcxx-commits mailing list