The best I can determine is that symbols defined in the parent class are no longer carried into the child class by default. This is counter to the way I've always believed C++ to work.
template<typename T>
class Parent
{
public:
typedef T* iterator;
};
template<typename T>
class Child : public Parent < T >
{
public:
//using iterator = Parent<T>::iterator; // this fixes error C3646 and error C2059
iterator begin(void)
{
return nullptr;
}
};
1>Test1.cpp(14,1): error C3646: 'begin': unknown override specifier
1>Test1.cpp(18): message : see reference to class template instantiation 'Child<T>' being compiled
1>Test1.cpp(14,16): error C2059: syntax error: '('
1>Test1.cpp(15,1): error C2334: unexpected token(s) preceding '{'; skipping apparent function body
This started happening when I changed the file settings to use C++14 or C++17, prior to that it was OK. There appears to be no way to restore the prior behavior, even selecting "Default" generates the errors. It still works fine in Visual Studio 2013.