New submission from Georg Brandl:

This is a request to be able to name C arguments differently from Python 
arguments.

Two reasons:

* like for function renaming, some Python argument names are reserved in C 
("default" for example, used in sys.getsizeof())

* sometimes the function uses 'O' in PyArg_ParseTuple and then converts the 
object itself with a nontrivial process.  Usually the converted variable has 
the name of the Python argument, while the temporary object is named "obj_foo" 
or "foo_obj".  When converting to Argument Clinic, we have to name the object 
"foo" and find a new name for the converted "foo", which leads to code churn 
and less beautiful code.

----------
assignee: larry
messages: 207948
nosy: georg.brandl, larry
priority: normal
severity: normal
status: open
title: Argument Clinic: rename arguments in generated C?

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue20227>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to