From 9c96cd958d43b53a55fb652bc9fd17700e282f42 Mon Sep 17 00:00:00 2001 From: David Wendt Date: Thu, 27 Apr 2023 20:16:19 -0400 Subject: [PATCH] Fix structs_column_wrapper ctors to copy input column wrappers --- cpp/include/cudf_test/column_wrapper.hpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/cpp/include/cudf_test/column_wrapper.hpp b/cpp/include/cudf_test/column_wrapper.hpp index 87fbfdc0dad..fd2c3699cf1 100644 --- a/cpp/include/cudf_test/column_wrapper.hpp +++ b/cpp/include/cudf_test/column_wrapper.hpp @@ -1807,7 +1807,9 @@ class structs_column_wrapper : public detail::column_wrapper { std::transform(child_column_wrappers.begin(), child_column_wrappers.end(), std::back_inserter(child_columns), - [&](auto column_wrapper) { return column_wrapper.get().release(); }); + [&](auto const& column_wrapper) { + return std::make_unique(column_wrapper.get()); + }); init(std::move(child_columns), validity); } @@ -1841,7 +1843,9 @@ class structs_column_wrapper : public detail::column_wrapper { std::transform(child_column_wrappers.begin(), child_column_wrappers.end(), std::back_inserter(child_columns), - [&](auto column_wrapper) { return column_wrapper.get().release(); }); + [&](auto const& column_wrapper) { + return std::make_unique(column_wrapper.get()); + }); init(std::move(child_columns), validity_iter); }