This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2014年01月08日 21:17 by serhiy.storchaka, last changed 2022年04月11日 14:57 by admin. This issue is now closed.
| Files | ||||
|---|---|---|---|---|
| File name | Uploaded | Description | Edit | |
| larry.zero.positional.parameters.patch.1.txt | larry, 2014年01月10日 01:58 | review | ||
| Messages (6) | |||
|---|---|---|---|
| msg207700 - (view) | Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) | Date: 2014年01月08日 21:17 | |
Argument Clinic generates invalid code for optional parameter if there are no mandatory parameters except self. Example:
/*[clinic input]
zlib.Decompress.flush
self: self(type="compobject *")
[
length: uint
the initial size of the output buffer.
]
/
Return a bytes object containing any remaining decompressed data.
[clinic start generated code]*/
Generates:
...
switch (PyTuple_Size(args)) {
case 0:
if (!PyArg_ParseTuple(args, ":flush", ))
return NULL;
break;
...
Note a comma in PyArg_ParseTuple.
|
|||
| msg207701 - (view) | Author: Larry Hastings (larry) * (Python committer) | Date: 2014年01月08日 21:25 | |
Good catch! It should be an easy fix, but I won't be able to get to it until tomorrow. |
|||
| msg207817 - (view) | Author: Larry Hastings (larry) * (Python committer) | Date: 2014年01月10日 01:58 | |
Here's a fix. Works for me, let me know if it works for you. |
|||
| msg207963 - (view) | Author: Larry Hastings (larry) * (Python committer) | Date: 2014年01月12日 16:24 | |
Georg, you mind reviewing this too? Six line patch. Just trying to clean my plate a little before I fix a bug for you :D |
|||
| msg207968 - (view) | Author: Roundup Robot (python-dev) (Python triager) | Date: 2014年01月12日 16:49 | |
New changeset 250b481a0d28 by Larry Hastings in branch 'default': Issue #20196: Fixed a bug where Argument Clinic did not generate correct http://hg.python.org/cpython/rev/250b481a0d28 |
|||
| msg207969 - (view) | Author: Larry Hastings (larry) * (Python committer) | Date: 2014年01月12日 16:50 | |
Easy fix. Thanks for the report! |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:57:56 | admin | set | github: 64395 |
| 2014年01月12日 16:50:39 | larry | set | status: open -> closed resolution: fixed messages: + msg207969 stage: patch review -> commit review |
| 2014年01月12日 16:49:49 | python-dev | set | nosy:
+ python-dev messages: + msg207968 |
| 2014年01月12日 16:24:55 | larry | set | nosy:
+ georg.brandl messages: + msg207963 |
| 2014年01月10日 01:58:16 | larry | set | stage: needs patch -> patch review |
| 2014年01月10日 01:58:07 | larry | set | files:
+ larry.zero.positional.parameters.patch.1.txt messages: + msg207817 |
| 2014年01月09日 07:28:42 | serhiy.storchaka | link | issue20168 dependencies |
| 2014年01月08日 21:25:14 | larry | set | assignee: larry type: behavior messages: + msg207701 stage: needs patch |
| 2014年01月08日 21:17:00 | serhiy.storchaka | create | |