MCPcopy Create free account
hub / github.com/LadybugDB/ladybug / resize

Method resize

src/include/storage/disk_array.h:395–402  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

393 inline U& operator[](uint64_t idx) { return *(U*)vector[idx]; }
394
395 inline void resize(uint64_t newNumElements) {
396 // NOLINTNEXTLINE(readability-non-const-parameter) placement-new requires non-const ptr
397 static constexpr auto defaultConstructor = [](uint8_t* data) {
398 [[maybe_unused]] auto* p = new (data) U();
399 DASSERT(p);
400 };
401 vector.resize(newNumElements, defaultConstructor);
402 }
403
404 inline uint64_t size() const { return vector.size(); }
405

Callers

nothing calls this directly

Calls 1

resizeMethod · 0.45

Tested by

no test coverage detected