else if (type == RegionType::Heap)
xbt_assert(not object_info, "Unexpected object info for heap region.");
- auto* region = new Region(page_store_, memory, type, start_addr, size);
+ auto region = std::make_unique<Region>(page_store_, memory, type, start_addr, size);
region->object_info(object_info);
- snapshot_regions_.push_back(std::unique_ptr<Region>(region));
+ snapshot_regions_.push_back(std::move(region));
}
void* Snapshot::read_bytes(void* buffer, std::size_t size, RemotePtr<void> address, ReadOptions options) const