Update src/distribution.cpp

Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
This commit is contained in:
Paul Wilson 2023-03-22 21:42:06 -04:00 committed by GitHub
parent 72a6f77b0c
commit 9bb1ef4369
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -27,7 +27,7 @@ DiscreteIndex::DiscreteIndex(pugi::xml_node node)
auto params = get_node_array<double>(node, "parameters");
std::size_t n = params.size() / 2;
assign(&(*params.begin()) + n, n);
assign(params.data() + n, n);
}
DiscreteIndex::DiscreteIndex(const double* p, int n)