Skip to content

Commit

Permalink
Proclaim return type in matrix_wrappers.hpp.
Browse files Browse the repository at this point in the history
  • Loading branch information
bdice committed Sep 12, 2023
1 parent 84b57d4 commit 5610b98
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions cpp/include/raft/spectral/detail/matrix_wrappers.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@
#include <thrust/reduce.h>
#include <thrust/system/cuda/execution_policy.h>

#include <cuda/functional>

#include <algorithm>

// =========================================================
Expand Down Expand Up @@ -111,11 +113,11 @@ class vector_t {
buffer_.data(),
buffer_.data() + buffer_.size(),
value_type{0},
[] __device__(auto left, auto right) {
cuda::proclaim_return_type<value_type>([] __device__(auto left, auto right) {
auto abs_left = left > 0 ? left : -left;
auto abs_right = right > 0 ? right : -right;
return abs_left + abs_right;
});
}));
}

void fill(value_type value)
Expand Down

0 comments on commit 5610b98

Please sign in to comment.