NiHu
2.0
is_specialisation.hpp
Go to the documentation of this file.
1
// This file is a part of NiHu, a C++ BEM template library.
2
//
3
// Copyright (C) 2012-2014 Peter Fiala <fiala@hit.bme.hu>
4
// Copyright (C) 2012-2014 Peter Rucz <rucz@hit.bme.hu>
5
//
6
// This program is free software: you can redistribute it and/or modify
7
// it under the terms of the GNU General Public License as published by
8
// the Free Software Foundation, either version 3 of the License, or
9
// (at your option) any later version.
10
//
11
// This program is distributed in the hope that it will be useful,
12
// but WITHOUT ANY WARRANTY; without even the implied warranty of
13
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
// GNU General Public License for more details.
15
//
16
// You should have received a copy of the GNU General Public License
17
// along with this program. If not, see <http://www.gnu.org/licenses/>.
18
25
#ifndef IS_SPECIALISATION_HPP_INCLUDED
26
#define IS_SPECIALISATION_HPP_INCLUDED
27
28
#include <type_traits>
29
30
namespace
NiHu
31
{
32
33
namespace
internal
34
{
41
template
<
class
T>
42
struct
enable_if_type
43
{
44
typedef
void
type;
45
};
46
}
// end of namespace internal
47
55
template
<
class
T,
class
Enable =
void
>
56
struct
is_specialisation
57
: std::true_type {};
58
59
68
template
<
class
T>
69
struct
is_specialisation
<T,
70
typename internal::enable_if_type<typename T::unspecialised>::type
71
>
72
: std::false_type {};
73
74
}
// end of namespace NiHu
75
76
#endif
/* IS_SPECIALISATION_HPP_INCLUDED */
NiHu::is_specialisation
Metafunction that determines if a type is a specialisation.
Definition:
is_specialisation.hpp:56
src
util
is_specialisation.hpp
Generated on Wed Mar 12 2025 01:00:17 for NiHu by
1.8.18