Direct-BT v3.3.0-1-gc2d430c
Direct-BT - Direct Bluetooth Programming.
Classes | Macros | Functions
test_type_traits_queries01.cpp File Reference
#include <cassert>
#include <cinttypes>
#include <cstring>
#include <iostream>
#include <jau/test/catch2_ext.hpp>
#include <jau/type_traits_queries.hpp>
Include dependency graph for test_type_traits_queries01.cpp:

Go to the source code of this file.

Classes

struct  Not
 
struct  One
 
struct  Two
 

Macros

#define CHECK_2(name, desc, ...)
 

Functions

 METHOD_CHECKER (has_get, get, long,())
 
 METHOD_CHECKER_ANY (any_get, get,())
 
 MTYPE_CHECKER (has_x, x)
 
 MTYPE_CHECKER_ANY (any_x, x)
 
 MTYPE_CHECKER_STRICT (exact_x, x)
 
 TEST_CASE ("01 Type Traits Queries")
 

Macro Definition Documentation

◆ CHECK_2

#define CHECK_2 (   name,
  desc,
  ... 
)
Value:
std::cout << std::endl; \
std::cout << "One " << (name<One, ##__VA_ARGS__>() ? "has " : "does not have ") << desc << std::endl; \
std::cout << "Two " << (name<Two, ##__VA_ARGS__>() ? "has " : "does not have ") << desc << std::endl; \
std::cout << "Not " << (name<Not, ##__VA_ARGS__>() ? "has " : "does not have ") << desc << std::endl; \
std::cout << "int " << (name<int, ##__VA_ARGS__>() ? "has " : "does not have ") << desc << std::endl
Examples
test_type_traits_queries01.cpp.

Function Documentation

◆ MTYPE_CHECKER()

MTYPE_CHECKER ( has_x  ,
 
)

◆ MTYPE_CHECKER_ANY()

MTYPE_CHECKER_ANY ( any_x  ,
 
)

◆ MTYPE_CHECKER_STRICT()

MTYPE_CHECKER_STRICT ( exact_x  ,
 
)

◆ METHOD_CHECKER()

METHOD_CHECKER ( has_get  ,
get  ,
long  ,
()   
)

◆ METHOD_CHECKER_ANY()

METHOD_CHECKER_ANY ( any_get  ,
get  ,
()   
)

◆ TEST_CASE()

TEST_CASE ( "01 Type Traits Queries"  )