You can't remove the implementation from the header. because a template implementation must be visible in the time of instantiation.
So you can either just move the implementation outside of the class below the class, or in a different header (if you want to have all the implementation in once file).
template<typename T>
class stable_vector
{
template<typename itor>
stable_vector(itor, itor,
typename std::enable_if<!std::is_integral<itor>::value>::type* = nullptr);
};
template <typenmae T> template<typename itor>
stable_vector<T>::stable_vector itor, itor,
typename std::enable_if<!std::is_integral<itor>::value>::type* = nullptr)
{
}
Or if you want to put it in a different file:
foo.h:
template<typename T>
class stable_vector
{
template<typename itor>
stable_vector(itor, itor,
typename std::enable_if<!std::is_integral<itor>::value>::type* = nullptr);
};
//include implementation file after decleration
#include fooImplementation.h
fooImplementation.h:
template <typenmae T> template<typename itor>
stable_vector<T>::stable_vector itor, itor,
typename std::enable_if<!std::is_integral<itor>::value>::type* = nullptr)
{
}