Alexander Belopolsky
f0f45142d5
Issue #2443 : Added a new macro, Py_VA_COPY, which is equivalent to C99
...
va_copy, but available on all python platforms. Untabified a few
unrelated files.
2010-08-11 17:31:17 +00:00
Victor Stinner
8182b717db
Issue #8991 : convertbuffer() rejects discontigious buffers
2010-07-28 00:40:58 +00:00
Victor Stinner
25e8ec4724
Issue #8850 : Remove "w" and "w#" formats from PyArg_Parse*() functions, use
...
"w*" format instead. Add tests for "w*" format.
2010-06-25 00:02:38 +00:00
Victor Stinner
21e09487ac
getbuffer(): release the buffer on error (if the buffer is not contiguous)
2010-06-24 22:57:10 +00:00
Victor Stinner
3c9e6e9375
PyArg_Parse*() functions: factorize code for s/z and u/Z formats
2010-06-24 22:31:12 +00:00
Victor Stinner
4aae1ebab2
Issue #8949 : "z" format of PyArg_Parse*() functions doesn't accept bytes
...
objects, as described in the documentation.
2010-06-24 22:08:25 +00:00
Victor Stinner
510b6227a7
getargs.c: remove last reference to "t#" format
...
"t#" format was removed from convertitem() (convertsimple) but not skipitem().
2010-06-13 20:31:26 +00:00
Victor Stinner
06e49dd029
Issue #8592 : PyArg_Parse*() functions raise a TypeError for "y", "u" and "Z"
...
formats if the string contains a null byte/character. Write unit tests for
string formats.
2010-06-13 18:21:50 +00:00
Mark Dickinson
c73013127b
Issue #8950 : Make PyArg_Parse* with 'L' code raise for float inputs,
...
instead of warning. This makes it consistent with the other integer
codes.
2010-06-10 16:05:10 +00:00
Victor Stinner
3dcb5acdb0
Issue #8838 , #8339 : Remove codecs.charbuffer_encode() and "t#" parsing format
...
Remove last references to the "char buffer" of the buffer protocol from
Python3.
2010-06-08 22:54:19 +00:00
Victor Stinner
5216e6d598
PyArg_Parse*("Z#") raises an error for unknown type
...
instead of ignoring the error and leave the pointer to the string and the size
unchanged (not initialized).
Fix also the type in the error message of "Z", "Z#" and "Y" formats.
2010-06-08 21:45:51 +00:00
Victor Stinner
2872e5b1f8
convertsimple(): call PyErr_NoMemory() on PyMem_NEW() failure
...
Raise a more revelant error (MemoryError instead of TypeError)
2010-06-06 20:38:02 +00:00
Victor Stinner
5cb6239f00
Simplify getbuffer(): convertbuffer() fails anyway if bf_getbuffer is NULL
2010-06-06 20:27:51 +00:00
Victor Stinner
43fb0097f3
Remove dead code
2010-05-29 00:13:06 +00:00
Victor Stinner
33109a142b
Issue #8837 : Remove "O?" format of PyArg_Parse*() functions. The format is no
...
used anymore and it was never documented.
2010-05-28 21:55:10 +00:00
Victor Stinner
93b5513cf1
Issue #6697 : Fix a crash if a keyword contains a surrogate
2010-05-19 00:54:06 +00:00
Antoine Pitrou
f95a1b3c53
Recorded merge of revisions 81029 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r81029 | antoine.pitrou | 2010-05-09 16:46:46 +0200 (dim., 09 mai 2010) | 3 lines
Untabify C files. Will watch buildbots.
........
2010-05-09 15:52:27 +00:00
Benjamin Peterson
fb88636199
prevent the dict constructor from accepting non-string keyword args #8419
...
This adds PyArg_ValidateKeywordArguments, which checks that keyword arguments
are all strings, using an optimized method if possible.
2010-04-24 18:21:17 +00:00
Antoine Pitrou
f96b78437b
Merged revisions 79837 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r79837 | antoine.pitrou | 2010-04-06 17:38:25 +0200 (mar., 06 avril 2010) | 19 lines
14 years later, we still don't know what it's for.
Spotted by the PyPy developers.
Original commit is:
branch: trunk
user: guido
date: Mon Aug 19 21:32:04 1996 +0200
files: Python/getargs.c
description:
[svn r6499] Support for keyword arguments (PyArg_ParseTupleAndKeywords) donated by
Geoff Philbrick <philbric@delphi.hks.com> (slightly changed by me).
Also a little change to make the file acceptable to K&R C compilers
(HPUX, SunOS 4.x).
........
2010-04-06 16:01:57 +00:00
Mark Dickinson
de60401909
Merged revisions 77218 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77218 | mark.dickinson | 2010-01-01 17:27:30 +0000 (Fri, 01 Jan 2010) | 5 lines
Issue #5080 : turn the DeprecationWarning from float arguments passed
to integer PyArg_Parse* format codes into a TypeError. Add a
DeprecationWarning for floats passed with the 'L' format code, which
didn't previously have a warning.
........
2010-01-01 19:27:32 +00:00
Mark Dickinson
f08173bb93
Issue #7414 : Add missing 'case 'C'' to skipitem() in getargs.c. This
...
was causing PyArg_ParseTupleAndKeywords(args, kwargs, "|CC", ...) to
fail with a RuntimeError. Thanks Case Van Horsen for tracking down
the source of this error.
2009-12-03 10:59:46 +00:00
Skip Montanaro
ba1e0f46ab
Issue 7147 - remove ability to attempt to build Python without complex number support (was broken anyway)
2009-10-18 14:25:35 +00:00
Sean Reifscheider
642d96a647
- Issue #6624 : yArg_ParseTuple with "s" format when parsing argument with
...
NUL: Bogus TypeError detail string.
2009-08-01 23:55:06 +00:00
Martin v. Löwis
c15bdef819
Issue #6012 : Add cleanup support to O& argument parsing.
2009-05-29 14:47:46 +00:00
Benjamin Peterson
b173f7853e
add a replacement API for PyCObject, PyCapsule #5630
...
All stdlib modules with C-APIs now use this.
Patch by Larry Hastings
2009-05-05 22:31:58 +00:00