Top "Sfinae" questions

Substitution failure is not an error.

How to detect existence of a class using SFINAE?

Is it possible to detect if a class exists in C++ using SFINAE? If possible then how? Suppose we have …

c++ templates sfinae
Template specialization and enable_if problems

I am running into a problem regarding the appropriate usage of enable_if and template specialization. After modifying the example (…

c++ templates c++11 sfinae enable-if
What is decltype with two arguments?

Edit, in order to avoid confusion: decltype does not accept two arguments. See answers. The following two structs can be …

c++ c++11 sfinae typetraits decltype
Detect operator support with decltype/SFINAE

A (somewhat) outdated article explores ways to use decltype along with SFINAE to detect if a type supports certain operators, …

c++ c++11 sfinae decltype
How to use sfinae for selecting constructors?

In template meta programming, one can use SFINAE on the return type to choose a certain template member function, i.…

c++ c++11 constructor sfinae
Issue with enable_if and multiple conditions

I tried to implement a function which converts a generic type to a string. Integral types need to be converted …

c++ templates c++14 sfinae enable-if
can I use SFINAE to selectively define a member variable in a template class?

So what I want to do is to create a template class which may or may not contain a member …

c++ sfinae