Skip to content

Commit

Permalink
Type traits update #40
Browse files Browse the repository at this point in the history
  • Loading branch information
Zerg1996 committed Oct 7, 2022
1 parent f3a8433 commit b7fff15
Showing 1 changed file with 5 additions and 10 deletions.
15 changes: 5 additions & 10 deletions include/nil/crypto3/detail/type_traits.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,16 +135,11 @@ namespace nil {

template<typename T>
struct is_codec {
static const bool value = has_type_encoded_value_type<T>::value &&
has_static_member_data_encoded_value_bits<T, const std::size_t>::value &&
has_type_decoded_value_type<T>::value &&
has_static_member_data_decoded_value_bits<T, const std::size_t>::value &&
has_type_encoded_block_type<T>::value &&
has_static_member_data_encoded_block_bits<T, const std::size_t>::value &&
has_type_decoded_block_type<T>::value &&
has_static_member_data_decoded_block_bits<T, const std::size_t>::value &&
has_member_function_encode<T, typename T::block_type>::value &&
has_member_function_decode<T, typename T::block_type>::value;
static const bool value = has_encoded_value_type<T>::value && has_encoded_value_bits<T>::value &&
has_decoded_value_type<T>::value && has_decoded_value_bits<T>::value &&
has_encoded_block_type<T>::value && has_encoded_block_bits<T>::value &&
has_decoded_block_type<T>::value && has_decoded_block_bits<T>::value &&
has_encode<T>::value && has_decode<T>::value;
typedef T type;
};

Expand Down

0 comments on commit b7fff15

Please sign in to comment.