Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SYCL] Fix EnableIfOutputIteratorT trait #12834

Closed
wants to merge 13 commits into from
4 changes: 3 additions & 1 deletion sycl/include/sycl/detail/common.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@ using EnableIfOutputPointerT = std::enable_if_t<

template <typename DataT>
using EnableIfOutputIteratorT = std::enable_if_t<
/*is_output_iterator<DataT>::value &&*/ !std::is_pointer_v<DataT>>;
/*is_output_iterator<DataT>::value &&*/ !std::is_pointer_v<DataT> &&
!std::is_const_v<std::remove_reference_t<
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Line 34 has the same bug.
  2. Have you checked if comment at line 30 is up-to-date?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will check if its prossible to uncomment the is_output_iterator trait then I'll get back to you. If this is unblocked then this PR is done.

Copy link
Contributor Author

@lbushi25 lbushi25 Feb 27, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aelovikov-intel It looks like the problem was with void* ptr so I added a full specialization for that case. This enabled me to uncomment the is_output_iterator. Let me know of any concerns!

typename std::iterator_traits<DataT>::reference>>>;

#if !defined(NDEBUG) && (_MSC_VER > 1929 || __has_builtin(__builtin_FILE))
#define __CODELOC_FILE_NAME __builtin_FILE()
Expand Down
Loading