[Python-ideas] String interpolation again.

Andrey Popp 8mayday at gmail.com
Fri Jul 23 14:26:09 CEST 2010


I think it's a form of weak typing from languages like PHP, that
allows programmer to make huge amounts of mistakes, that are sometimes
difficult to spot.

On Fri, Jul 23, 2010 at 4:10 PM, INADA Naoki <songofacandy at gmail.com> wrote:
> Hi, all.
>
> Below code is syntax error now:
>
> foo = 123
> x = 'foo' foo 'bar'
>
> I wonder if that code is interpreted as:
>
> x = 'foo' + str(foo) + 'bar'
>  or
> x = 'foo%sbar' % (foo,)
>
> I think this syntax sugar doesn't import any compatibility problem
> and simple enough for Python.
>
> What do you think about it?
>
> --
> INADA Naoki  <songofacandy at gmail.com>
> _______________________________________________
> Python-ideas mailing list
> Python-ideas at python.org
> http://mail.python.org/mailman/listinfo/python-ideas
>



-- 
Andrey Popp

phone: +7 911 740 24 91
e-mail: 8mayday at gmail.com



More information about the Python-ideas mailing list