always return matching types in bin_views

This commit is contained in:
Hans Dembinski
2018-03-11 20:51:03 +01:00
parent 37ccf6d80c
commit 3a7c8cb715
5 changed files with 17 additions and 9 deletions

View File

@@ -153,10 +153,7 @@ template <typename A> bp::object axis_getitem(const A &a, int i) {
PyErr_SetString(PyExc_IndexError, "index out of bounds");
bp::throw_error_already_set();
}
return axis_getitem_impl(std::is_same<
typename A::bin_type, bha::interval_view<A>
>(), a, i);
return bp::object();
return axis_getitem_impl(bh::detail::has_method_lower_t<A>(), a, i);
}
template <typename T> void axis_set_label(T& t, bp::str s) {