[Python-ideas] Descouraging the implicit string concatenation
eryk sun
eryksun at gmail.com
Wed Mar 14 08:56:43 EDT 2018
On Wed, Mar 14, 2018 at 12:18 PM, Facundo Batista
<facundobatista at gmail.com> wrote:
>
> Note that there's no penalty in adding the '+' between the strings,
> those are resolved at compilation time.
The above statement is not true for versions prior to 3.7. Previously
the addition of string literals was optimized by the peephole
optimizer, with a limit of 20 characters. Do you mean to formally
discourage implicit string-literal concatenation only for 3.7+?
More information about the Python-ideas
mailing list