MCPcopy Create free account
hub / github.com/VectorDB-NTU/RaBitQ-Library / size

Function size

include/rabitqlib/utils/array.hpp:34–40  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

32 */
33template <typename Dims>
34[[nodiscard]] constexpr auto size(const Dims& dims) -> size_t {
35 static_assert(std::is_same_v<typename Dims::value_type, size_t>);
36
37 size_t res = 1;
38 std::for_each(dims.begin(), dims.end(), [&](auto cur_d) { res *= cur_d; });
39 return res;
40}
41} // namespace array_impl
42
43template <

Callers 4

sizeMethod · 0.70
bytesMethod · 0.70
destroyMethod · 0.70
ArrayMethod · 0.70

Calls 2

beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected