MCPcopy Create free account
hub / github.com/alibaba/zvec / reset

Method reset

src/ailego/container/vector_array.h:477–481  ·  view source on GitHub ↗

Reset the vector array

Source from the content-addressed store, hash-verified

475
476 //! Reset the vector array
477 void reset(size_t dim) {
478 dimension_ = (dim + (sizeof(ValueType) << 3) - 1) /
479 (sizeof(ValueType) << 3) * (sizeof(ValueType) << 3);
480 buffer_.clear();
481 }
482
483 //! Requests the removal of unused capacity.
484 void shrink_to_fit() {

Callers

nothing calls this directly

Calls 1

clearMethod · 0.45

Tested by

no test coverage detected