[issue27855] 2to3: Wrong code output w/ has_key without trailing space

2016-08-25 Thread E Rippey
E Rippey added the comment: I have one line change to "Lib/lib2to3/fixes/fix_has_key.py" that will resolve this issue. Would a patch be accepted? It doesn't seem like the input is unusually contorted. -- status: closed -> open ___ P

[issue27855] 2to3: Wrong code output w/ has_key

2016-08-24 Thread E Rippey
New submission from E Rippey: The "has_key" fixer in 2to3 produces wrong code on the following example: input:"a.has_key(b)and x" output:"b in aand x" Note the lack of space before "and" in the input. -- components: 2to3 (2.x to 3.x conversi