]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Don't use __has_trivial_copy 14534/head
authorDaniel Arndt <arndtd@ornl.gov>
Mon, 5 Dec 2022 19:29:10 +0000 (14:29 -0500)
committerDaniel Arndt <arndtd@ornl.gov>
Mon, 5 Dec 2022 19:40:47 +0000 (14:40 -0500)
include/deal.II/lac/vector_operations_internal.h

index d40e9c91b706e6f08bf01a46347afd7f526b5035..10ecc4f860b0513b2cb825c454efa7e38284d62d 100644 (file)
@@ -247,17 +247,12 @@ namespace internal
       {
         Assert(end >= begin, ExcInternalError());
 
-#if __GNUG__ && __GNUC__ < 5
-        if (__has_trivial_copy(Number) &&
-            std::is_same<Number, OtherNumber>::value)
-#else
-#  ifdef DEAL_II_HAVE_CXX17
+#ifdef DEAL_II_HAVE_CXX17
         if constexpr (std::is_trivially_copyable<Number>() &&
                       std::is_same<Number, OtherNumber>::value)
-#  else
+#else
         if (std::is_trivially_copyable<Number>() &&
             std::is_same<Number, OtherNumber>::value)
-#  endif
 #endif
           std::memcpy(dst + begin, src + begin, (end - begin) * sizeof(Number));
         else

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.