Re: Hashmaps
From: Greg Comeau (comeau_at_panix.com)
Date: 12/05/03
- Next message: Jumbo: "Re: trouble creating array of objects"
- Previous message: Gene Wirchenko: "Re: <ctype.h> toLower()"
- In reply to: Jon Cosby: "Re: Hashmaps"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 5 Dec 2003 12:07:59 -0500
In article <kM1Ab.201$rP6.200@newsread2.news.pas.earthlink.net>,
Jon Cosby <qwerty@nospam.net> wrote:
>"Robert W Hand" <rwhand@NOSPAMoperamail.com> wrote in message
>news:00hvsvopnm5gdqm3k4jvrbm1ps7elg0rar@4ax.com...
>> On Sat, 29 Nov 2003 17:10:01 GMT, "Jon Cosby" <qwerty@abc.net> wrote:
>>
>> > hash_map <int, string> hm1;
>> > typedef pair <int, string> str_pair;
>> >
>> > hm1.insert(str_pair(1, "Hello"));
>> >
>> >crashes, pointing to something in "xhash". Is there a brief tutorial on
>> >this
>> >somewhere?
>>
>> I am not aware that hash_map is in the C++ Standard. SGI has come
>> information at
>>
>> http://www.sgi.com/tech/stl/hash_map.html
>>
>> Dinkum has information about it too, but I cannot get them online at
>> present. Other vendors who offer it as an extension may also have
>> documentation papers. Lastly, there are books since it is a common
>> extension with several different implementations.
>> --
>
>Thanks for the info. No, I guess it's not part of the standard C++ library.
>VC lists it so, though.
(Jumbo ellie phant take note of what Jon just said -- see
how misinformation sometimes gets spread by MS documentation?
(In fairness, this is not just an MS problem.))
Robert is correct, there is no hash_map in standard C++.
However, many implementations provide (different) ones
(libcomo has what I'll call a defunct one, since it's not
supported by Standard C++). Furthermore, the C++ Library
TR (Technical Report), which is not part of any Standard C++,
contains one, and it's _likely_ to become part of C++0x,
perhaps with some modifications still.
-- Greg Comeau/4.3.3:Full C++03 core language + more Windows backends Comeau C/C++ ONLINE ==> http://www.comeaucomputing.com/tryitout World Class Compilers: Breathtaking C++, Amazing C99, Fabulous C90. Comeau C/C++ with Dinkumware's Libraries... Have you tried it?
- Next message: Jumbo: "Re: trouble creating array of objects"
- Previous message: Gene Wirchenko: "Re: <ctype.h> toLower()"
- In reply to: Jon Cosby: "Re: Hashmaps"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|