1
0
skypjack 3 сар өмнө
parent
commit
9e7a31cc74

+ 2 - 2
src/entt/core/algorithm.hpp

@@ -99,8 +99,8 @@ struct radix_sort {
         if(first < last) {
             constexpr auto passes = N / Bit;
 
-            using value_type = typename std::iterator_traits<It>::value_type;
-            using difference_type = typename std::iterator_traits<It>::difference_type;
+            using value_type = std::iterator_traits<It>::value_type;
+            using difference_type = std::iterator_traits<It>::difference_type;
             std::vector<value_type> aux(static_cast<std::size_t>(std::distance(first, last)));
 
             auto part = [getter = std::move(getter)](auto from, auto to, auto out, auto start) {

+ 5 - 5
src/entt/core/hashed_string.hpp

@@ -61,19 +61,19 @@ class basic_hashed_string: internal::basic_hashed_string<Char> {
 
     struct const_wrapper {
         // non-explicit constructor on purpose
-        constexpr const_wrapper(const typename base_type::value_type *str) noexcept
+        constexpr const_wrapper(const base_type::value_type *str) noexcept
             : repr{str} {}
 
-        const typename base_type::value_type *repr;
+        const base_type::value_type *repr;
     };
 
 public:
     /*! @brief Character type. */
-    using value_type = typename base_type::value_type;
+    using value_type = base_type::value_type;
     /*! @brief Unsigned integer type. */
-    using size_type = typename base_type::size_type;
+    using size_type = base_type::size_type;
     /*! @brief Unsigned integer type. */
-    using hash_type = typename base_type::hash_type;
+    using hash_type = base_type::hash_type;
 
     /**
      * @brief Returns directly the numeric representation of a string view.

+ 1 - 1
src/entt/core/iterator.hpp

@@ -140,7 +140,7 @@ template<typename Type>
 template<typename It, typename Sentinel = It>
 struct iterable_adaptor final {
     /*! @brief Value type. */
-    using value_type = typename std::iterator_traits<It>::value_type;
+    using value_type = std::iterator_traits<It>::value_type;
     /*! @brief Iterator type. */
     using iterator = It;
     /*! @brief Sentinel type. */

+ 3 - 3
src/entt/core/memory.hpp

@@ -76,7 +76,7 @@ struct allocation_deleter: private Allocator {
     /*! @brief Allocator type. */
     using allocator_type = Allocator;
     /*! @brief Pointer type. */
-    using pointer = typename std::allocator_traits<Allocator>::pointer;
+    using pointer = std::allocator_traits<Allocator>::pointer;
 
     /**
      * @brief Inherited constructors.
@@ -109,8 +109,8 @@ template<typename Type, typename Allocator, typename... Args>
 constexpr auto allocate_unique(Allocator &allocator, Args &&...args) {
     static_assert(!std::is_array_v<Type>, "Array types are not supported");
 
-    using alloc_traits = typename std::allocator_traits<Allocator>::template rebind_traits<Type>;
-    using allocator_type = typename alloc_traits::allocator_type;
+    using alloc_traits = std::allocator_traits<Allocator>::template rebind_traits<Type>;
+    using allocator_type = alloc_traits::allocator_type;
 
     allocator_type alloc{allocator};
     auto ptr = alloc_traits::allocate(alloc, 1u);

+ 15 - 15
src/entt/core/type_traits.hpp

@@ -125,7 +125,7 @@ struct type_list_element<0u, type_list<First, Other...>> {
  * @tparam List Type list to search into.
  */
 template<std::size_t Index, typename List>
-using type_list_element_t = typename type_list_element<Index, List>::type;
+using type_list_element_t = type_list_element<Index, List>::type;
 
 /*! @brief Primary template isn't defined on purpose. */
 template<typename, typename>
@@ -210,7 +210,7 @@ struct type_list_cat<> {
 template<typename... Type, typename... Other, typename... List>
 struct type_list_cat<type_list<Type...>, type_list<Other...>, List...> {
     /*! @brief A type list composed by the types of all the type lists. */
-    using type = typename type_list_cat<type_list<Type..., Other...>, List...>::type;
+    using type = type_list_cat<type_list<Type..., Other...>, List...>::type;
 };
 
 /**
@@ -228,7 +228,7 @@ struct type_list_cat<type_list<Type...>> {
  * @tparam List Type lists to concatenate.
  */
 template<typename... List>
-using type_list_cat_t = typename type_list_cat<List...>::type;
+using type_list_cat_t = type_list_cat<List...>::type;
 
 /*! @cond TURN_OFF_DOXYGEN */
 namespace internal {
@@ -255,7 +255,7 @@ struct type_list_unique<type_list<>, Type...> {
 template<typename List>
 struct type_list_unique {
     /*! @brief A type list without duplicate types. */
-    using type = typename internal::type_list_unique<List>::type;
+    using type = internal::type_list_unique<List>::type;
 };
 
 /**
@@ -263,7 +263,7 @@ struct type_list_unique {
  * @tparam List Type list.
  */
 template<typename List>
-using type_list_unique_t = typename type_list_unique<List>::type;
+using type_list_unique_t = type_list_unique<List>::type;
 
 /**
  * @brief Provides the member constant `value` to true if a type list contains a
@@ -311,7 +311,7 @@ struct type_list_diff<type_list<Type...>, type_list<Other...>> {
  * @tparam List Type lists between which to compute the difference.
  */
 template<typename... List>
-using type_list_diff_t = typename type_list_diff<List...>::type;
+using type_list_diff_t = type_list_diff<List...>::type;
 
 /*! @brief Primary template isn't defined on purpose. */
 template<typename, template<typename...> class>
@@ -335,7 +335,7 @@ struct type_list_transform<type_list<Type...>, Op> {
  * @tparam Op Unary operation as template class with a type member named `type`.
  */
 template<typename List, template<typename...> class Op>
-using type_list_transform_t = typename type_list_transform<List, Op>::type;
+using type_list_transform_t = type_list_transform<List, Op>::type;
 
 /**
  * @brief A class to use to push around lists of constant values, nothing more.
@@ -382,7 +382,7 @@ struct value_list_element<0u, value_list<Value, Other...>> {
  * @tparam List Value list to search into.
  */
 template<std::size_t Index, typename List>
-using value_list_element_t = typename value_list_element<Index, List>::type;
+using value_list_element_t = value_list_element<Index, List>::type;
 
 /**
  * @brief Helper type.
@@ -475,7 +475,7 @@ struct value_list_cat<> {
 template<auto... Value, auto... Other, typename... List>
 struct value_list_cat<value_list<Value...>, value_list<Other...>, List...> {
     /*! @brief A value list composed by the values of all the value lists. */
-    using type = typename value_list_cat<value_list<Value..., Other...>, List...>::type;
+    using type = value_list_cat<value_list<Value..., Other...>, List...>::type;
 };
 
 /**
@@ -493,7 +493,7 @@ struct value_list_cat<value_list<Value...>> {
  * @tparam List Value lists to concatenate.
  */
 template<typename... List>
-using value_list_cat_t = typename value_list_cat<List...>::type;
+using value_list_cat_t = value_list_cat<List...>::type;
 
 /*! @brief Primary template isn't defined on purpose. */
 template<typename>
@@ -525,7 +525,7 @@ struct value_list_unique<value_list<>> {
  * @tparam Type A value list.
  */
 template<typename Type>
-using value_list_unique_t = typename value_list_unique<Type>::type;
+using value_list_unique_t = value_list_unique<Type>::type;
 
 /**
  * @brief Provides the member constant `value` to true if a value list contains
@@ -573,7 +573,7 @@ struct value_list_diff<value_list<Value...>, value_list<Other...>> {
  * @tparam List Value lists between which to compute the difference.
  */
 template<typename... List>
-using value_list_diff_t = typename value_list_diff<List...>::type;
+using value_list_diff_t = value_list_diff<List...>::type;
 
 /*! @brief Same as std::is_invocable, but with tuples. */
 template<typename, typename>
@@ -817,7 +817,7 @@ struct constness_as<To, const From> {
  * @tparam From The type from which to transcribe the constness.
  */
 template<typename To, typename From>
-using constness_as_t = typename constness_as<To, From>::type;
+using constness_as_t = constness_as<To, From>::type;
 
 /**
  * @brief Extracts the class of a non-static member object or function.
@@ -846,7 +846,7 @@ public:
  * @tparam Member A pointer to a non-static member object or function.
  */
 template<typename Member>
-using member_class_t = typename member_class<Member>::type;
+using member_class_t = member_class<Member>::type;
 
 /**
  * @brief Extracts the n-th argument of a _callable_ type.
@@ -881,7 +881,7 @@ public:
  * @tparam Candidate A valid function, member function or data member type.
  */
 template<std::size_t Index, typename Candidate>
-using nth_argument_t = typename nth_argument<Index, Candidate>::type;
+using nth_argument_t = nth_argument<Index, Candidate>::type;
 
 } // namespace entt