preCICE
v3.1.2
Loading...
Searching...
No Matches
src
utils
traits.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include <
type_traits
>
4
5
namespace
precice
{
6
namespace
utils {
7
8
// Implementation of C++17 std::conjunction taken from https://en.cppreference.com/w/cpp/types/conjunction
9
template
<
class
...>
10
struct
conjunction
:
std::true_type
{
11
};
12
13
template
<
class
B1>
14
struct
conjunction<B1>
: B1 {
15
};
16
17
template
<
class
B1,
class
... Bn>
18
struct
conjunction
<B1, Bn...>
19
:
std::conditional
<bool(B1::value), conjunction<Bn...>, B1>::type {
20
};
21
22
template
<
class
F,
class
... Inputs>
23
struct
type_transform
{
24
};
25
26
template
<
class
P,
class
A1,
class
... A>
27
struct
transform
;
28
29
}
// namespace utils
30
}
// namespace precice
std::conditional
std::true_type
precice
Main namespace of the precice library.
Definition
Acceleration.cpp:5
precice::utils::conjunction
Definition
traits.hpp:10
precice::utils::transform
Definition
traits.hpp:27
precice::utils::type_transform
Definition
traits.hpp:23
type_traits