Created
November 7, 2017 00:03
-
-
Save adiog/690a75459e9a6523b73a5742722ee876 to your computer and use it in GitHub Desktop.
sfinae_class
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <type_traits> | |
template <typename T, typename Enable = void> | |
class foo; | |
template <typename T> | |
class foo<T, typename std::enable_if<std::is_integral<T>::value>::type> | |
{ }; | |
template <typename T> | |
class foo<T, typename std::enable_if<std::is_floating_point<T>::value>::type> | |
{ }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment