From 833caddb863a56c4039a715d7988f09b2f9ace1a Mon Sep 17 00:00:00 2001 From: Nghia Truong Date: Wed, 13 Jul 2022 13:19:19 -0700 Subject: [PATCH] Fix compile error due to missing header (#11257) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The recently merged PR (https://github.com/rapidsai/cudf/pull/11137) did not include the `` header which may cause compile error in some systems (in particular, CUDA 11.7 + gcc-11.2): ``` error: ‘std::optional’ has not been declared error: ‘optional’ in namespace ‘std’ does not name a template type ``` This PR adds that missing header to fix the compile issue. Authors: - Nghia Truong (https://github.com/ttnghia) Approvers: - Gera Shegalov (https://github.com/gerashegalov) - David Wendt (https://github.com/davidwendt) - Mike Wilson (https://github.com/hyperbolic2346) URL: https://github.com/rapidsai/cudf/pull/11257 --- cpp/include/cudf/detail/null_mask.cuh | 1 + cpp/include/cudf/detail/reduction_functions.hpp | 2 ++ cpp/include/cudf/reduction.hpp | 2 ++ cpp/src/reductions/simple_segmented.cuh | 1 + 4 files changed, 6 insertions(+) diff --git a/cpp/include/cudf/detail/null_mask.cuh b/cpp/include/cudf/detail/null_mask.cuh index 8b6edd77476..c596404b784 100644 --- a/cpp/include/cudf/detail/null_mask.cuh +++ b/cpp/include/cudf/detail/null_mask.cuh @@ -39,6 +39,7 @@ #include #include +#include #include namespace cudf { diff --git a/cpp/include/cudf/detail/reduction_functions.hpp b/cpp/include/cudf/detail/reduction_functions.hpp index 58cf2dc84e7..7877fe13951 100644 --- a/cpp/include/cudf/detail/reduction_functions.hpp +++ b/cpp/include/cudf/detail/reduction_functions.hpp @@ -23,6 +23,8 @@ #include +#include + namespace cudf { namespace reduction { /** diff --git a/cpp/include/cudf/reduction.hpp b/cpp/include/cudf/reduction.hpp index e479c6f47ce..083892aa856 100644 --- a/cpp/include/cudf/reduction.hpp +++ b/cpp/include/cudf/reduction.hpp @@ -21,6 +21,8 @@ #include +#include + namespace cudf { /** * @addtogroup aggregation_reduction diff --git a/cpp/src/reductions/simple_segmented.cuh b/cpp/src/reductions/simple_segmented.cuh index 7dde713e638..774b9075736 100644 --- a/cpp/src/reductions/simple_segmented.cuh +++ b/cpp/src/reductions/simple_segmented.cuh @@ -38,6 +38,7 @@ #include #include +#include #include namespace cudf {