]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Use std::common_type_t<...> instead of typename std::common_type<...>::type.
authorWolfgang Bangerth <bangerth@colostate.edu>
Wed, 8 Mar 2023 13:16:23 +0000 (06:16 -0700)
committerWolfgang Bangerth <bangerth@colostate.edu>
Wed, 8 Mar 2023 13:16:23 +0000 (06:16 -0700)
include/deal.II/base/exceptions.h

index 2f7416e4f2a45402f60778e1ee5eeb30c6398e0f..b2739df6cc94675a0e3665cd84892408df3a5c38 100644 (file)
@@ -1712,7 +1712,7 @@ namespace deal_II_exceptions
     inline constexpr bool
     compare_for_equality(const T &t, const U &u)
     {
-      using common_type = typename std::common_type<T, U>::type;
+      using common_type = std::common_type_t<T, U>;
       return static_cast<common_type>(t) == static_cast<common_type>(u);
     }
 
@@ -1726,7 +1726,7 @@ namespace deal_II_exceptions
     inline constexpr bool
     compare_less_than(const T &t, const U &u)
     {
-      using common_type = typename std::common_type<T, U>::type;
+      using common_type = std::common_type_t<T, U>;
       return (static_cast<common_type>(t) < static_cast<common_type>(u));
     }
   } // namespace internals
@@ -1822,8 +1822,9 @@ namespace internal
   Assert(                                                                      \
     ::dealii::deal_II_exceptions::internals::compare_less_than(index, range),  \
     dealii::ExcIndexRangeType<typename ::dealii::internal::argument_type<void( \
-      typename std::common_type<decltype(index), decltype(range)>::type)>::    \
-                                type>((index), 0, (range)))
+      std::common_type_t<decltype(index), decltype(range)>)>::type>((index),   \
+                                                                    0,         \
+                                                                    (range)))
 
 /**
  * An assertion that checks whether a number is finite or not. We explicitly

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.