[Python-ideas] Syntax idea: escaping names to avoid keyword ambiguity

Terry Reedy tjreedy at udel.edu
Mon May 14 14:11:54 EDT 2018


On 5/14/2018 10:02 AM, Clint Hepner wrote:
> 
>> On 2018 May 14 , at 6:47 a, Daniel Moisset <dmoisset at machinalis.com> wrote:
>>
>> Following up some of the discussions about the problems of adding keywords and Guido's proposal of making tokenization context-dependent, I wanted to propose an alternate way to go around the problem.
> 
> My main objection to what follows is that it doesn't seem to offer any benefit over the current practice of appending an underscore (_) to a keyword to make it a valid identifier.

Tkinter uses this convention for a few option names that clash.

-- 
Terry Jan Reedy



More information about the Python-ideas mailing list