alpaka
Abstraction Library for Parallel Kernel Acceleration
Loading...
Searching...
No Matches
include
alpaka
mem
concepts
IndexVec.hpp
Go to the documentation of this file.
1
/* Copyright 2025 Simeon Ehrig
2
* SPDX-License-Identifier: MPL-2.0
3
*/
4
5
#pragma once
6
#include "
alpaka/Vec.hpp
"
7
8
namespace
alpaka::concepts
9
{
10
/** Check whether the specified type is a multidimensional index.
11
*
12
* @details The type must fulfill alpaka::concepts::Vector, and its type must be convertible to an expected index
13
* type without loss of precision.
14
*
15
* @tparam T_IndexType expected index type
16
* @tparam T_Dim expected dimension
17
*/
18
template
<
typename
T,
typename
T_IndexType, auto T_Dim>
19
concept
IndexVec
=
requires
{
20
requires
concepts::Vector<T, alpaka::NotRequired, T_Dim>
;
21
requires
isLosslesslyConvertible_v<typename T::type, T_IndexType>
;
22
};
23
}
// namespace alpaka::concepts
Vec.hpp
alpaka::concepts::IndexVec
Check whether the specified type is a multidimensional index.
Definition
IndexVec.hpp:19
alpaka::concepts::Vector
Concept to check if a type is a vector.
Definition
Vec.hpp:53
alpaka::concepts
Definition
api.hpp:32
alpaka::isLosslesslyConvertible_v
constexpr bool isLosslesslyConvertible_v
Definition
trait.hpp:122
Generated on
for alpaka by
1.16.1