I'm currently looking for a better alternative to std::map and have come across classes mentioned in the post title. Could someone clarify the differences between them, not in terms of performance/API, but in terms of where they beleong in relation to the current and forthcomnig standard.
If you can, use std::unordered_map as it's the final name of the hash map implementation (if you need a hash map). The others names are there in case your compiler provide them but in a separate namespace (as C++0x is not yet available officially).
There is boost::unordered_map too by the way, but it's almost all the same idea and interface.
The headers in <tr1/*>
are things which were specified in TR1 'draft'. I believe a lot of these are likely to progress into C++0x (although this isn't guaranteed and there is scope for incompatible changes too). <ext/*>
is non-standard (i.e. vendor specific) extensions as I understand it. Boost also provides an unordered_map which may be handy if you're trying to target compilers which provide none of the headers you mentioned.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With