[Python-ideas] Proposal for new augmented assignment operator for method calls

Alexander Belopolsky alexander.belopolsky at gmail.com
Fri Mar 27 23:01:17 CET 2015


On Fri, Mar 27, 2015 at 5:36 PM, Jamie Willis <jw14896.2014 at my.bristol.ac.uk>
wrote:
>
> I would like to propose a new piece of syntax for the python language; .=
>
> In short, the operator is form of syntactic sugar, for instance consider
the following code:
>
>> hello = "hello world              "
>> hello = hello.strip()
>
>
> This could be written as:
>
>> hello = "hello world              "
>> hello .= strip()


"Syntax must not look like grit on Tim's screen!"

-1
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20150327/cc37ae59/attachment.html>


More information about the Python-ideas mailing list