Skip to content

Conversation

@slawekptak
Copy link
Contributor

The KernelType definition, used to check if a kernel is using a kernel_handler argument, should be a pure lambda type, so remove const and reference declarations.

The KernelType definition, used to check if a kernel is using
a kernel_handler argument, should be a pure lambda type,
so remove const and reference declarations.
Copy link
Contributor

@aelovikov-intel aelovikov-intel left a comment

Choose a reason for hiding this comment

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

While on it, I'd suggest using

#if __has_builtin(__type_pack_element)
template <int N, typename... Ts>
using nth_type_t = __type_pack_element<N, Ts...>;
#else
template <int N, typename T, typename... Ts> struct nth_type {
using type = typename nth_type<N - 1, Ts...>::type;
};
template <typename T, typename... Ts> struct nth_type<0, T, Ts...> {
using type = T;
};
template <int N, typename... Ts>
using nth_type_t = typename nth_type<N, Ts...>::type;
#endif

and change to std::decay_t<detail::nth_type_t<RestT...>>.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants