https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91436
--- Comment #7 from Jonathan Wakely <redi at gcc dot gnu.org> --- (In reply to Konstantin Kharlamov from comment #0) > When the reason for an undefined function is too low c++ standard, g++ still > suggests to include the header where it's supposed to be. N.B. this isn't true in general, it was true only for std::make_unique and the namespace std::complex_literals. In general it should tell you the problem is the -std option, and that's what happens for your example now: 91436.cc: In function 'int main()': 91436.cc:4:21: error: 'make_unique' is not a member of 'std' auto foo = std::make_unique<char>(); ^~~~~~~~~~~ 91436.cc:4:21: note: 'std::make_unique' is only available from C++14 onwards 91436.cc:4:33: error: expected primary-expression before 'char' auto foo = std::make_unique<char>(); ^~~~