classification
Title: Argument Clinic rollup fixes
Type: behavior Stage: resolved
Components: Versions: Python 3.4
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: larry Nosy List: georg.brandl, larry, python-dev
Priority: normal Keywords:

Created on 2014-01-10 01:25 by larry, last changed 2014-01-13 22:02 by larry. This issue is now closed.

Files
File name Uploaded Description Edit
larry.argument.clinic.misc.fixes.patch.1.txt larry, 2014-01-10 01:25 review
larry.argument.clinic.misc.fixes.patch.2.txt larry, 2014-01-12 16:46 review
larry.argument.clinic.misc.fixes.patch.3.txt larry, 2014-01-12 18:22 review
Messages (6)
msg207811 - (view) Author: Larry Hastings (larry) * (Python committer) Date: 2014-01-10 01:25
Miscellaneous Argument Clinic fixes:
  * Added default value type verification for almost all return converters.
  * Added return converters for float, dobule, unsigned long,
    unsigned int, short, and unsigned short.
  * Py_buffer converter improvements:
      * Now allow exactly one value as a default value: None.
      * The default value in C only needs two fields initialized.
      * The cleanup call to PyBuffer_Release should be based on
        ".obj", not ".buf".
As well as a bunch of documentation fixes.

I'd love a review, but I'm pretty confident it's all okay so I may just check it in.  (The only code changes are in clinic.py so it's not going to break the world.)
msg207961 - (view) Author: Larry Hastings (larry) * (Python committer) Date: 2014-01-12 16:18
Freshened patch,
msg207965 - (view) Author: Larry Hastings (larry) * (Python committer) Date: 2014-01-12 16:29
Also adding the one-byte fix from #20201 to the rollup patch here.  (Not bothering to upload a fresh patch because it is literally one byte, fixing a misspelled variable name.)
msg207967 - (view) Author: Larry Hastings (larry) * (Python committer) Date: 2014-01-12 16:46
I goofed, I do have some additional fixes.  Here's everything.

Changes since patch #1:
* Added 'converter' argument to 'object' converter.
* Fixed misspelled variable name (see #20201).
* Several documentation updates.
msg207977 - (view) Author: Larry Hastings (larry) * (Python committer) Date: 2014-01-12 18:22
Third patch, with these new features:

* Relaxed rules regarding c_default and py_default; they can now be
  used even when no default value is supplied.
* Added bool return converter.
* Made one fail() call easier to read, through the power of str.format().
* More doc updates and fixes.
msg207978 - (view) Author: Roundup Robot (python-dev) Date: 2014-01-12 19:10
New changeset 3eee3967d03f by Larry Hastings in branch 'default':
Issue #20214: Fixed a number of small issues and documentation errors in
http://hg.python.org/cpython/rev/3eee3967d03f
History
Date User Action Args
2014-01-13 22:02:55larrysetstatus: open -> closed
resolution: fixed
stage: patch review -> resolved
2014-01-12 19:10:15python-devsetnosy: + python-dev
messages: + msg207978
2014-01-12 18:22:41larrysetfiles: + larry.argument.clinic.misc.fixes.patch.3.txt

messages: + msg207977
2014-01-12 16:46:01larrysetfiles: + larry.argument.clinic.misc.fixes.patch.2.txt

messages: + msg207967
2014-01-12 16:29:20larrysetmessages: + msg207965
2014-01-12 16:18:26larrysetnosy: + georg.brandl
messages: + msg207961
2014-01-10 01:25:38larrycreate