From -5268420347108869204
X-Google-Thread: f78e5,d50382f3e5ec6b4e
X-Google-Thread: 109fba,d50382f3e5ec6b4e
X-Google-Attributes: gidf78e5,gid109fba,public
X-Google-Language: ENGLISH,ASCII-7-bit
Path: g2news1.google.com!news4.google.com!news.glorb.com!news.zanker.org!border2.nntp.ams.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!pe2.news.blueyonder.co.uk!blueyonder!peer-uk.news.demon.net!kibo.news.demon.net!news.demon.co.uk!demon!stump.algebra.com!devnull
From: tom_usenet@hotmail.com (Tom Widmer)
Newsgroups: comp.std.c++,comp.lang.c++
Subject: Re: The issue of const maps and operator[]
Date: Sat,  4 Dec 2004 02:26:30 GMT
Organization: [posted via Easynet UK]
Lines: 35
Sender: mail2news@demon.net
Approved: fjh@cs.mu.oz.au (Fergus Henderson , moderator of comp.std.c++)
Message-ID: <fuf0r09ebfrj9b1eponqd039k537agbrvb@4ax.com>
References: <3171vsF37jfq7U1@individual.net> <YWxrd.191852$hj.44035@fed1read07> <41aef8cf$0$66398$14726298@news.sunsite.dk>
NNTP-Posting-Host: news.news.demon.net
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Trace: news.demon.co.uk 1102127206 4808 158.152.254.254 (4 Dec 2004 02:26:46 GMT)
X-Complaints-To: abuse@demon.net
NNTP-Posting-Date: Sat, 4 Dec 2004 02:26:46 +0000 (UTC)
X-Robomod: STUMP, ichudov@algebra.com (Igor Chudov)
X-Virus-Scanned: by amavisd-new at cs.mu.OZ.AU
X-Path: comp-std-cpp-robomod!not-for-mail
X-Received: (from fjh@localhost)
	by mulga.cs.mu.OZ.AU (8.12.10+Sun/8.12.9/Submit) id iB42QUZA026505;
	Sat, 4 Dec 2004 13:26:30 +1100 (EST)
X-Delivered-To: std-c++@ucar.edu
X-Authentication-Warning: mulga.cs.mu.OZ.AU: fjh set sender to devnull@stump.algebra.com using -f
X-Newsreader: Forte Free Agent 2.0/32.652
X-Newsgroups: comp.std.c++,comp.lang.c++
Xref: g2news1.google.com comp.std.c++:3570 comp.lang.c++:32661

On Fri,  3 Dec 2004 02:54:24 GMT, nesotto@cs.auc.dk ("Thorsten
Ottosen") wrote:

>"James Dennett" <jdennett@acm.org> wrote in message 
>news:YWxrd.191852$hj.44035@fed1read07...
>
>> In spite of having found several discussions on this topic, I could not
>> find mention of whether this issue is going to be addressed when C++
>> gets its next major revision.
>
>|I find it enormously unlikely that this would be changed in the
>|next revision of C++.
>
>yes true. but we are already looking into adding
>
>T& map<K,T>::at( const Key& );
>const T& map<K,T>::at( const Key& ) const;
>
>which should throw if nothing is found.

I like the symmetry with vector::at.

>Alternatively, I guess we could use operator()().

I don't like that, since operator() hasn't been used like that
elsewhere and is usually used for functors.

Tom 

---
[ 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                       ]



