Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
wichtounet committed Apr 24, 2015
1 parent 825383a commit 8f6908f
Showing 1 changed file with 0 additions and 16 deletions.
16 changes: 0 additions & 16 deletions include/etl/unary_expr.hpp
Expand Up @@ -285,31 +285,15 @@ struct unary_expr<T, Expr, virtual_op> : comparable<unary_expr<T, Expr, virtual_

//Apply the expression

value_type operator[](std::size_t i){
return value()[i];
}

value_type operator[](std::size_t i) const {
return value()[i];
}

template<bool B = (sub_size_compare<this_type>::value > 1), cpp::enable_if_u<B> = cpp::detail::dummy>
value_type operator()(std::size_t i){
return sub(*this, i);
}

template<bool B = (sub_size_compare<this_type>::value > 1), cpp::enable_if_u<B> = cpp::detail::dummy>
value_type operator()(std::size_t i) const {
return sub(*this, i);
}

template<typename... S>
std::enable_if_t<sizeof...(S) == sub_size_compare<this_type>::value, value_type> operator()(S... args){
static_assert(cpp::all_convertible_to<std::size_t, S...>::value, "Invalid size types");

return value()(args...);
}

template<typename... S>
std::enable_if_t<sizeof...(S) == sub_size_compare<this_type>::value, value_type> operator()(S... args) const {
static_assert(cpp::all_convertible_to<std::size_t, S...>::value, "Invalid size types");
Expand Down

0 comments on commit 8f6908f

Please sign in to comment.