Guest User

Untitled

a guest
Apr 24th, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.32 KB | None | 0 0
  1. template<typename T, typename = void> // sth like T=>int or T=>double not valid
  2. struct test : std::false_type{};
  3.  
  4. template<typename T, ???> // what should i do?
  5. struct test<T,???> : std::true_type{};
  6.  
  7. std::cout << test<int>::value << std::endl;
  8.  
  9. class a{ int a;double b};
  10. std::cout << test<a>::value << std::endl;
Add Comment
Please, Sign In to add comment