Topic: Missing containers/tuples in proposed hash support of n1756 in view


Author: dsp@bdal.de (=?ISO-8859-1?Q?Daniel_Kr=FCgler?=)
Date: Wed, 17 Aug 2005 13:51:25 GMT
Raw View
Hello,

http://www.open-std.org/JTC1/SC22/WG21/docs/papers/2005/n1756.pdf

recommends in 6.18 to add more hash support for some selected
container-like classes, namely

std::basic_string<>
std::vector<>
std::list<>
std::deque<>
std::set<>
std::multiset<>
std::map<>
std::multimap<>

and for the tuple-like

std::pair<>

I would like to increase these lists by the following container-like=20
classes:

std::unordered_set<>
std::unordered_multiset<>
std::unordered_map<>
std::unordered_multimap<>

and for the following tuple-like class

std::tr1::tuple<>

1) There is no real reason, why the newly introduced unordered=20
containers should be viewed as second-class citizens for hashing ;-)

2) Writing a home-grown generalized hasher for tuple<> is sufficiently
complex for programming beginners to justify this addition. I don't see=20
a similar need for e.g. std::tr1::array or std::bitset.

Greetings from Bremen,

Daniel Kr=FCgler

---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.jamesd.demon.co.uk/csc/faq.html                       ]