Alex Rivera | Logout

How to get rid of g++ hash_map deprecation warning?

Asked 2009-04-06T17:21:39.533
10

When I compile a c++ application I'm writing that makes use of hash_map, I get this warning on g++ 4.3.2:

You are using the deprecated header . To eliminate this warning, use an ANSI-standard header file or use hte -Wno-deprecated compiler flag.

9> #include <ext/hash_map>

What include replaces this? I've searched for a while on google, and can't find anything except for people having similar problems, but no solution.

Edit
Report

1 Answer

6

I believe that that new data structure is called unordered_map

<tr1/unordered_map>

found in the std::tr1 namespace.

answered 2009-04-06T17:28:49.360

Your Answer