Control Surface
main
MIDI Control Surface library for Arduino
Toggle main menu visibility
Loading...
Searching...
No Matches
src
MIDI_Interfaces
BLEMIDI
Util
compat.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include <
Settings/NamespaceSettings.hpp
>
4
5
#include <cstddef>
6
#include <type_traits>
7
#include <utility>
8
9
BEGIN_CS_NAMESPACE
10
11
#if __cplusplus >= 201703L
12
13
namespace
compat
{
14
using
std::byte;
15
using
std::in_place;
16
using
std::in_place_t;
17
using
std::in_place_type;
18
using
std::in_place_type_t;
19
}
// namespace compat
20
21
#else
22
23
namespace
compat
{
24
struct
in_place_t
{
25
explicit
in_place_t
() =
default
;
26
};
27
static
in_place_t
in_place
{};
28
template
<
class
T>
29
struct
in_place_type_t
{
30
explicit
in_place_type_t
() =
default
;
31
};
32
template
<
class
T>
33
static
in_place_type_t<T>
in_place_type
{};
34
enum class
byte
:
unsigned
char
{};
35
}
// namespace compat
36
37
#endif
38
39
#if __cplusplus >= 202002L
40
41
namespace
compat
{
42
using
std::remove_cvref;
43
}
// namespace compat
44
45
#else
46
47
namespace
compat
{
48
template
<
class
T>
49
struct
remove_cvref
{
50
using
type
=
51
typename
std::remove_cv<typename std::remove_reference<T>::type>
::type
;
52
};
53
}
// namespace compat
54
55
#endif
56
57
END_CS_NAMESPACE
NamespaceSettings.hpp
END_CS_NAMESPACE
#define END_CS_NAMESPACE
Definition
Settings/NamespaceSettings.hpp:14
BEGIN_CS_NAMESPACE
#define BEGIN_CS_NAMESPACE
Definition
Settings/NamespaceSettings.hpp:11
compat
Definition
compat.hpp:23
compat::in_place
static in_place_t in_place
Definition
compat.hpp:27
compat::byte
byte
Definition
compat.hpp:34
compat::in_place_type
static in_place_type_t< T > in_place_type
Definition
compat.hpp:33
compat::in_place_t
Definition
compat.hpp:24
compat::in_place_t::in_place_t
in_place_t()=default
compat::in_place_type_t
Definition
compat.hpp:29
compat::in_place_type_t::in_place_type_t
in_place_type_t()=default
compat::remove_cvref
Definition
compat.hpp:49
compat::remove_cvref::type
typename std::remove_cv< typename std::remove_reference< T >::type >::type type
Definition
compat.hpp:50
Generated by
1.17.0