LeechCraft
0.6.70-16373-g319c272718
Modular cross-platform feature rich live environment.
Loading...
Searching...
No Matches
detector.h
Go to the documentation of this file.
1
/**********************************************************************
2
* LeechCraft - modular cross-platform feature rich internet client.
3
* Copyright (C) 2006-2014 Georg Rudoy
4
*
5
* Distributed under the Boost Software License, Version 1.0.
6
* (See accompanying file LICENSE or copy at https://www.boost.org/LICENSE_1_0.txt)
7
**********************************************************************/
8
9
#pragma once
10
11
#include <type_traits>
12
13
namespace
LC
14
{
15
namespace
Util
16
{
17
namespace
detail
18
{
19
template
<
typename
Default,
typename
Placeholder
,
template
<
typename
...>
class
Op
,
typename
...
Args
>
20
struct
IsDetected
21
{
22
using
value_t
= std::false_type;
23
using
type
= Default;
24
};
25
26
template
<
typename
Default,
template
<
typename
...>
class
Op
,
typename
...
Args
>
27
struct
IsDetected
<Default,
std
::
void_t
<Op<Args...>>,
Op
,
Args
...>
28
{
29
using
value_t
= std::true_type;
30
using
type
=
Op
<
Args
...>;
31
};
32
}
33
34
template
<
template
<
typename
...>
class
Op
,
typename
...
Args
>
35
constexpr
bool
IsDetected_v
=
detail::IsDetected
<
void
,
void
,
Op
,
Args
...>::value_t::value;
36
37
template
<
typename
Type,
template
<
typename
...>
class
Op
,
typename
...
Args
>
38
using
IsDetected_t
=
typename
detail::IsDetected
<Type,
void
,
Op
,
Args
...>::type;
39
}
40
}
LC::Util::Filter
Container< T > Filter(const Container< T > &c, F f)
Definition
prelude.h:118
LC::Util::IsDetected_v
constexpr bool IsDetected_v
Definition
detector.h:35
LC::Util::IsDetected_t
typename detail::IsDetected< Type, void, Op, Args... >::type IsDetected_t
Definition
detector.h:38
LC
Definition
constants.h:15
std
STL namespace.
LC::Util::detail::Filter
Definition
typelist.h:103
LC::Util::detail::IsDetected< Default, std::void_t< Op< Args... > >, Op, Args... >::value_t
std::true_type value_t
Definition
detector.h:29
LC::Util::detail::IsDetected
Definition
detector.h:21
LC::Util::detail::IsDetected::value_t
std::false_type value_t
Definition
detector.h:22
LC::Util::detail::IsDetected::type
Default type
Definition
detector.h:23
src
util
sll
detector.h
Generated by
1.10.0