[Python-ideas] Crazy idea: allow keywords as names in certain positions
greg.ewing at canterbury.ac.nz
Tue May 15 18:59:06 EDT 2018
Steven D'Aprano wrote:
> So instead of having two classes of identifiers
> - those that can be used anywhere;
> - those that can only be used as dotted names;
> you would have two classes of keywords:
> - those that cannot be shadowed;
> - those that can be shadowed.
Yes. But we would always recommend that people not shadow
any keywords, just as we recommend that tney not shadow
builtins. All of this is purely to allow old code to keep
working and old APIs to be used.
More information about the Python-ideas