Functions
class_traits_t.cc File Reference
#include "gallery/Event.h"
#include <type_traits>

Go to the source code of this file.

Functions

template<typename T >
constexpr bool nothrow_destructible ()
 
template<typename T >
constexpr bool noncopyable ()
 
template<typename T >
constexpr bool nothrow_movable ()
 
int main ()
 

Function Documentation

int main ( void  )

Definition at line 28 of file class_traits_t.cc.

29 {
30  static_assert(not std::is_default_constructible_v<gallery::Event>);
31  static_assert(nothrow_destructible<gallery::Event>());
32  static_assert(noncopyable<gallery::Event>());
33  static_assert(nothrow_movable<gallery::Event>());
34 }
template<typename T >
constexpr bool noncopyable ( )

Definition at line 14 of file class_traits_t.cc.

15 {
16  return not std::is_copy_constructible_v<T>;
17 }
template<typename T >
constexpr bool nothrow_destructible ( )

Definition at line 7 of file class_traits_t.cc.

8 {
9  return std::is_nothrow_destructible_v<T>;
10 }
template<typename T >
constexpr bool nothrow_movable ( )

Definition at line 21 of file class_traits_t.cc.

22 {
23  return std::is_nothrow_move_constructible_v<T> and
24  std::is_nothrow_move_assignable_v<T>;
25 }