Pythonic way for missing dict keys

Alex Popescu nospam.themindstorm at gmail.com
Sun Jul 22 06:55:15 EDT 2007


Zentrader <zentraders at gmail.com> wrote in news:1185041243.323915.161230
@x40g2000prg.googlegroups.com:

> On Jul 21, 7:48 am, Duncan Booth <duncan.bo... at invalid.invalid> wrote:
>
> [snip...]
>
> 
>>From the 2.6 PEP #361 (looks like dict.has_key is deprecated)
> Python 3.0 compatability: ['compatibility'-->someone should use a
> spell-checker for 'official' releases]
>         - warnings were added for the following builtins which no
> longer exist in 3.0:
>              apply, callable, coerce, dict.has_key, execfile, reduce,
> reload
> 

I see... what that document doesn't describe is the alternatives to be 
used. And I see in that list a couple of functions that are probably used a 
lot nowadays (callable, reduce, etc.).

bests,
./alex
--
.w the_mindstorm )p.





More information about the Python-list mailing list