Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.001 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'sys': 0.04; 'dictionary': 0.07; 'terry': 0.07; '3.x': 0.09; 'sun,': 0.09; 'though:': 0.09; 'url:dev': 0.09; 'pm,': 0.11; 'am,': 0.14; 'wrote:': 0.14; 'reedy': 0.16; 'stumbled': 0.16; 'subject:key': 0.16; 'url:sys': 0.16; 'exists': 0.19; 'far.': 0.19; 'cc:no real name:2**0': 0.20; 'cc:2**0': 0.20; 'cheers,': 0.20; 'header:In-Reply-To:1': 0.22; 'cc:addr:python-list': 0.22; 'keys': 0.23; 'chris': 0.27; 'function': 0.27; 'message-id:@mail.gmail.com': 0.28; 'cc:addr:python.org': 0.31; 'detail.': 0.31; 'strings,': 0.31; 'however,': 0.31; 'url:library': 0.31; 'url:docs': 0.33; 'module': 0.33; 'actually': 0.34; 'url:python': 0.37; 'received:google.com': 0.38; 'but': 0.38; 'url:org': 0.38; 'header:Received:5': 0.40; '2011': 0.62; 'received:74.125.83': 0.69; 'hey,': 0.74; 'subject:original': 0.84; 'to:none': 0.92 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rebertia.com; s=google; h=domainkey-signature:mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:cc:content-type :content-transfer-encoding; bh=tKp4gKHaeMD6jIbv623PsCopjI0nrsSHTJJsL5/KIhY=; b=P0QWjxAtfp7xESkMeUKG2YkWaURUjQAs7Ox/WYtG8aHP/PkHkbkC+ploQamquxL3W2 5xRacdlCGQWaNcvOxacoW9Kw+jk+zgiH76IU1kFl8C4KTDk4bbZaYeJBc38nXCqPmuSA nfxj30tJV/kHC2Ur/tV11x/0z0A/PdIc2NJI4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=rebertia.com; s=google; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:cc:content-type :content-transfer-encoding; b=Dyd4dyeQT6pCsQPd+zrkAvbcIlqa7ZLiwLE8hIsPvFoodbKMS//ZGH1C5dC1HdlEZG WzV6rs0IMLpGzOp9eOHi8vrmjLyN47xk/ZnhTSSqQ9Y5vv700U8sTZclTXMp3EtHYgBR Eo/+dxmf6Kr+j5Uqb7+4s/FeF9cCEt4okn6CA= MIME-Version: 1.0 Sender: chris@rebertia.com In-Reply-To: References: <874o4wwenu.fsf@falma.de> <4dcfa885$0$29996$c3e8da3$5496439d@news.astraweb.com> <87sjsgutqg.fsf@falma.de> Date: Sun, 15 May 2011 14:19:42 -0700 X-Google-Sender-Auth: c1sLyGg85PAcdEol-tF9Q0bhYN8 Subject: Re: dict: retrieve the original key by key From: Chris Rebert Cc: python-list@python.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 15 NNTP-Posting-Host: 82.94.164.166 X-Trace: 1305494385 news.xs4all.nl 65870 [::ffff:82.94.164.166]:54145 X-Complaints-To: abuse@xs4all.nl Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:5448 On Sun, May 15, 2011 at 1:53 PM, Terry Reedy wrote: > On 5/15/2011 6:46 AM, Christoph Groth wrote: >> But hey, they keys of my dictionary are actually strings, so I can use >> the built-in intern. =C2=A0Somehow, I have never stumbled accross this >> built-in function so far. > > It was, however, removed in 3.x as a seldom-externally-used internal > implementation detail. Still exists in sys module though: http://docs.python.org/dev/library/sys.html#sys.intern Cheers, Chris