enable_if.hpp 592 Bytes
Newer Older
Umang Yadav's avatar
Umang Yadav committed
1
2
3

#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Weverything"
Chao Liu's avatar
Chao Liu committed
4
// SPDX-License-Identifier: MIT
Illia Silin's avatar
Illia Silin committed
5
// Copyright (c) 2018-2023, Advanced Micro Devices, Inc. All rights reserved.
Chao Liu's avatar
Chao Liu committed
6

7
#pragma once
Umang Yadav's avatar
Umang Yadav committed
8
9
10
11
12
13
#ifdef __HIPCC_RTC__
namespace std {
template <bool B, typename T = void>
using enable_if_t = typename enable_if<B, T>::type;
} // namespace std
#endif
Chao Liu's avatar
Chao Liu committed
14
15
namespace ck {

Umang Yadav's avatar
Umang Yadav committed
16
template <bool B, typename T = void> using enable_if = std::enable_if<B, T>;
Chao Liu's avatar
Chao Liu committed
17
18
19
20
21

template <bool B, typename T = void>
using enable_if_t = typename std::enable_if<B, T>::type;

} // namespace ck
Umang Yadav's avatar
Umang Yadav committed
22
23

#pragma clang diagnostic pop