py3k feature proposal: field auto-assignment in constructors

Ben Finney bignose+hates-spam at benfinney.id.au
Sun Jan 27 19:49:30 EST 2008


"André" <andre.roberge at gmail.com> writes:

> Personally, I like the idea you suggest, with the modification that I
> would use "." instead of "@", as in
> 
> class Server(object):
>     def __init__(self, .host, .port, .protocol, .bufsize, .timeout):
>         pass

-1.

That leading dot is too easy to miss when looking over the code.

-- 
 \        "Intellectual property is to the 21st century what the slave |
  `\                              trade was to the 16th." —David Mertz |
_o__)                                                                  |
Ben Finney



More information about the Python-list mailing list