kblib 0.2.3
General utilities library for modern C++
kblib::fakestd::detail::swappable_with< Tp, Up, NotVoid > Struct Template Reference

#include <kblib/fakestd.h>

Public Types

using swap1 = decltype((test_swap< Tp, Up >(0)))
 
using swap2 = decltype((test_swap< Up, Tp >(0)))
 

Static Public Member Functions

template<class LHS , class RHS >
static decltype(swap(std::declval< LHS >(), std::declval< RHS >())) test_swap (int)
 
template<class , class >
static nat test_swap (long)
 

Static Public Attributes

static const bool value
 

Detailed Description

template<class Tp, class Up = Tp, bool NotVoid = not std::is_void<Tp>::value and not std::is_void<Up>::value>
struct kblib::fakestd::detail::swappable_with< Tp, Up, NotVoid >

Definition at line 220 of file fakestd.h.

Member Typedef Documentation

◆ swap1

template<class Tp , class Up = Tp, bool NotVoid = not std::is_void<Tp>::value and not std::is_void<Up>::value>
using kblib::fakestd::detail::swappable_with< Tp, Up, NotVoid >::swap1 = decltype((test_swap<Tp, Up>(0)))

Definition at line 228 of file fakestd.h.

◆ swap2

template<class Tp , class Up = Tp, bool NotVoid = not std::is_void<Tp>::value and not std::is_void<Up>::value>
using kblib::fakestd::detail::swappable_with< Tp, Up, NotVoid >::swap2 = decltype((test_swap<Up, Tp>(0)))

Definition at line 229 of file fakestd.h.

Member Function Documentation

◆ test_swap() [1/2]

template<class Tp , class Up = Tp, bool NotVoid = not std::is_void<Tp>::value and not std::is_void<Up>::value>
template<class LHS , class RHS >
static decltype(swap(std::declval< LHS >(), std::declval< RHS >())) kblib::fakestd::detail::swappable_with< Tp, Up, NotVoid >::test_swap ( int  )
static

◆ test_swap() [2/2]

template<class Tp , class Up = Tp, bool NotVoid = not std::is_void<Tp>::value and not std::is_void<Up>::value>
template<class , class >
static nat kblib::fakestd::detail::swappable_with< Tp, Up, NotVoid >::test_swap ( long  )
static

Member Data Documentation

◆ value

template<class Tp , class Up = Tp, bool NotVoid = not std::is_void<Tp>::value and not std::is_void<Up>::value>
const bool kblib::fakestd::detail::swappable_with< Tp, Up, NotVoid >::value
static
Initial value:
= not std::is_same<swap1, nat>::value
and not std::is_same<swap2, nat>::value

Definition at line 231 of file fakestd.h.


The documentation for this struct was generated from the following file: