This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Why does this fail to compile in C++11 mode?


Maybe I'm being dumb, but shouldn't this compile with -std=c++11?
It does with -std=c++98

#include <algorithm>

struct X { };

bool operator==(const X&, const X&);

typedef X*           iterator_type;

namespace std
{
  template iterator_type remove(iterator_type, iterator_type, const X&);
}


The example is based on
testsuite/25_algorithms/remove/requirements/explicit_instantiation/2.cc
which fails if tested in C++11 or C++14 mode.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]