renaming weight to weight_counter, replacing asserts on user errors with throws, guide improvements

This commit is contained in:
Hans Dembinski
2017-11-10 16:38:58 +01:00
parent d3bba7c4bc
commit 0637deed4e
12 changed files with 229 additions and 164 deletions

View File

@@ -38,7 +38,7 @@ namespace python {
class access {
public:
using mp_int = histogram::detail::mp_int;
using weight = histogram::detail::weight;
using weight_counter = histogram::detail::weight_counter;
template <typename T>
using array = histogram::detail::array<T>;
@@ -58,7 +58,7 @@ public:
strides.append(sizeof(double));
return dtype_typestr<double>();
}
str operator()(const array<weight>& /*unused*/) const {
str operator()(const array<weight_counter>& /*unused*/) const {
strides.append(sizeof(double));
strides.append(strides[-1] * 2);
shapes.append(2);